//
// CI Training
//

#include "stagesetup.h"

// Characters
#define CHR_CARRINGTON 0x00

// Objects
#define OBJ_CAMSPY      0x26
#define OBJ_LIGHTSWITCH 0x34
#define OBJ_HOVERCRATE  0x93

// Stage flags
#define STAGEFLAG_IN_TRAINING            0x00000001
#define STAGEFLAG_HOLO_FAILED            0x00000002
#define STAGEFLAG_DEVICE_ABORTING        0x00000004
#define STAGEFLAG_TRIGGER_DEVICE_SUCCESS 0x00000008
#define STAGEFLAG_TRIGGER_DEVICE_FAILURE 0x00000010
#define STAGEFLAG_HOLO_ABORTING          0x00000020
#define STAGEFLAG_TRIGGER_HOLO_SUCCESS   0x00000040
#define STAGEFLAG_TRIGGER_HOLO_FAILURE   0x00000080
#define STAGEFLAG_TRIGGER_UPLINK         0x00000100
#define STAGEFLAG_TRIGGER_ECMMINE        0x00000200
#define STAGEFLAG_TRIGGER_CAMSPY         0x00000400
#define STAGEFLAG_TRIGGER_NIGHTVISION    0x00000800
#define STAGEFLAG_TRIGGER_DOORDECODER    0x00001000
#define STAGEFLAG_TRIGGER_RTRACKER       0x00002000
#define STAGEFLAG_TRIGGER_IR             0x00004000
#define STAGEFLAG_TRIGGER_XRAY           0x00008000
#define STAGEFLAG_TRIGGER_DISGUISE       0x00010000
#define STAGEFLAG_TRIGGER_CLOAK          0x00020000
#define STAGEFLAG_IN_HOLO1               0x00040000
#define STAGEFLAG_IN_HOLO2               0x00080000
#define STAGEFLAG_IN_HOLO3               0x00100000
#define STAGEFLAG_IN_HOLO4               0x00200000
#define STAGEFLAG_IN_HOLO5               0x00400000
#define STAGEFLAG_IN_HOLO6               0x00800000
#define STAGEFLAG_IN_HOLO7               0x01000000
#define STAGEFLAG_GENERAL_PURPOSE        0x02000000
#define STAGEFLAG_TRIGGER_CANNOTEXIT_MSG 0x04000000
#define STAGEFLAG_CONSIDER_WARP          0x08000000
#define STAGEFLAG_CLOAK_COMPLETE         0x10000000
#define STAGEFLAG_CLOAK_FAILED           0x20000000
#define STAGEFLAG_DISGUISE_FAILED        0x40000000
#define STAGEFLAG_DISGUISE_COMPLETE      0x80000000

// AI Lists
#define AILIST_MOVE_TO_DEVICEROOM             0x0401
#define AILIST_MOVE_TO_HOLOROOM               0x0402
#define AILIST_HOLO4_GUARD1                   0x0403
#define AILIST_HOLO4_GUARD2                   0x0404
#define AILIST_HOLO4_GUARD3                   0x0405
#define AILIST_HOLO5_INIT_GUARD1              0x0406
#define AILIST_HOLO5_GUARD1                   0x0407
#define AILIST_HOLO5_INIT_GUARD2              0x0408
#define AILIST_HOLO5_GUARD2                   0x0409
#define AILIST_HOLO5_INIT_GUARD3              0x040a
#define AILIST_HOLO5_GUARD3                   0x040b
#define AILIST_HOLO6_INIT_GUARD1              0x040c
#define AILIST_HOLO6_INIT_GUARD2              0x040d
#define AILIST_HOLO6_INIT_GUARD3              0x040e
#define AILIST_HOLO6_INIT_GUARD4              0x040f
#define AILIST_HOLO7_INIT_GUARD4              0x0410
#define AILIST_HOLO7_INIT_GUARD5              0x0411
#define AILIST_HOLO7_INIT_GUARD1              0x0412
#define AILIST_HOLO7_INIT_GUARD2              0x0413
#define AILIST_HOLO7_INIT_GUARD3              0x0414
#define AILIST_HOLO_GUARD_UNARMED_UNALERT     0x0415
#define AILIST_HOLO_GUARD_UNARMED_ALERT       0x0416
#define AILIST_HOLO_GUARD_UNARMED_ALERT2      0x0417
#define AILIST_HOLO_GUARD_ARMED_UNALERT       0x0418
#define AILIST_HOLO_GUARD_ARMED_ALERT         0x0419
#define AILIST_HOLO3_CHECK_DONE               0x041c
#define AILIST_INIT_COLLEAGUE_WHEN_SIGHTED    0x041d
#define AILIST_COLLEAGUE                      0x041e
#define AILIST_GRIMSHAW_DISGUISE              0x0429
#define AILIST_CARRINGTON_CLOAK               0x042a
#define AILIST_INIT_CARRINGTON                0x042b
#define AILIST_CARRINGTON_TOUR                0x042c
#define AILIST_DEVICEGIRL_REPLY_TO_CARRINGTON 0x042e
#define AILIST_HOLO1_CHECK_DONE               0x0430
#define AILIST_HOLO3_OBJECT1                  0x0435
#define AILIST_HOLO3_OBJECT2                  0x0436
#define AILIST_HOLO1_SWITCH1                  0x0437
#define AILIST_HOLO1_SWITCH2                  0x0438
#define AILIST_HOLO1_SWITCH3                  0x0439
#define AILIST_HOLO1_MONITOR_SWITCHES         0x043a

// Pads
#define PAD_OUTSIDE_JO_OFFICE 0x0053
#define PAD_CARRINGTON_OFFICE 0x00f6
#define PAD_DEVICEROOM        0x0121
#define PAD_HOLOROOM          0x0273

extern s32 intro[];
extern u32 props[];
extern struct path paths[];
extern struct ailist ailists[];

struct stagesetup setup = {
	NULL,
	NULL,
	NULL,
	intro,
	props,
	paths,
	ailists,
	NULL,
};

u32 props[] = {
	door(0x0100, MODEL_INSTFRONTDOOR, PAD_DISH_018D, OBJFLAG_ORTHOGONAL | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000008, 0x00000384, 0x00000000, 0x00000001, 0x00000300)
	door(0x0100, MODEL_INSTFRONTDOOR, PAD_DISH_018E, OBJFLAG_ORTHOGONAL | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000008, 0x00000384, 0x00000000, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_INSTFRONTDOOR, PAD_DISH_018F, OBJFLAG_ORTHOGONAL | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000008, 0x00000384, 0x00000000, 0x00000001, 0x00000300)
	door(0x0100, MODEL_INSTFRONTDOOR, PAD_DISH_0190, OBJFLAG_ORTHOGONAL | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000008, 0x00000384, 0x00000000, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_CIDOOR1_REF, PAD_DISH_0156, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000384, 0x00000000, 0x00000001, 0x00000800)
	door(0x0100, MODEL_CIDOOR1_REF, PAD_DISH_0157, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000384, 0x00000000, 0xffffffff, 0x00000000)
	tag(0x75, 2)
	tag(0x76, 2)
	door(0x0100, MODEL_CIDOOR1_REF, PAD_DISH_0158, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, OBJFLAG2_AICANNOTUSE, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000384, 0x00000000, 0x00000001, 0x00000800)
	door(0x0100, MODEL_CIDOOR1_REF, PAD_DISH_0159, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, OBJFLAG2_AICANNOTUSE, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000384, 0x00000000, 0xffffffff, 0x00000000)
	tag(0x8a, 1)
	door(0x0100, MODEL_CIDOOR1_REF, PAD_DISH_015B, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000384, 0x00000000, 0x00000000, 0x00000800)
	door(0x0100, MODEL_CIDOOR1_REF, PAD_DISH_015C, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000384, 0x00000000, 0x00000000, 0x00000800)
	tag(0x31, 1)
	door(0x0100, MODEL_CIDOOR1_REF, PAD_DISH_015A, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000384, 0x00000000, 0x00000000, 0x00000800)
	tag(0x89, 1)
	door(0x0100, MODEL_CIDOOR1_REF, PAD_DISH_015D, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000384, 0x00000000, 0x00000000, 0x00000800)
	tag(0x91, 2)
	tag(0x92, 1)
	door(0x0100, MODEL_DD_LIFTDOOR, PAD_DISH_018C, OBJFLAG_IGNOREFLOORCOLOUR, 0, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, 0, DOORTYPE_SLIDING, 0x00000000, 0x00000384, 0x00000000, 0x00000000, 0x00000300)
	stdobject(0x0100, MODEL_CI_SOFA, PAD_DISH_0212, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_NOFALL | OBJFLAG2_IMMUNETOGUNFIRE, OBJFLAG3_PUSHABLE, 1000)
	stdobject(0x0100, MODEL_CI_SOFA, PAD_DISH_0213, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_NOFALL | OBJFLAG2_IMMUNETOGUNFIRE, OBJFLAG3_PUSHABLE, 1000)
	stdobject(0x0100, MODEL_CI_SOFA, PAD_DISH_0214, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_NOFALL | OBJFLAG2_IMMUNETOGUNFIRE, OBJFLAG3_PUSHABLE, 1000)
	stdobject(0x0100, MODEL_CI_SOFA, PAD_DISH_0215, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_NOFALL | OBJFLAG2_IMMUNETOGUNFIRE, OBJFLAG3_PUSHABLE, 1000)
	stdobject(0x0100, MODEL_CI_SOFA, PAD_DISH_0216, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_NOFALL | OBJFLAG2_IMMUNETOGUNFIRE, OBJFLAG3_PUSHABLE, 1000)
	stdobject(0x0100, MODEL_CI_SOFA, PAD_DISH_0217, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_NOFALL | OBJFLAG2_IMMUNETOGUNFIRE, OBJFLAG3_PUSHABLE, 1000)
	stdobject(0x0100, MODEL_CI_SOFA, PAD_DISH_0218, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_NOFALL | OBJFLAG2_IMMUNETOGUNFIRE, OBJFLAG3_PUSHABLE, 1000)
	stdobject(0x0100, MODEL_CI_SOFA, PAD_DISH_0219, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_NOFALL | OBJFLAG2_IMMUNETOGUNFIRE, OBJFLAG3_PUSHABLE, 1000)
	stdobject(0x0100, MODEL_AIRBASE_SAFEDOOR, PAD_DISH_025B, OBJFLAG_00000008 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_BOUNCEIFSHOTWHENDEAD | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 4000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_019F, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, 0, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_019E, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, 0, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_019D, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, 0, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_019C, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, 0, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01A0, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, 0, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01A1, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, 0, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01A2, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, 0, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01A3, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, 0, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01A8, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01A9, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01AA, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01AB, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01AC, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01AD, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01AE, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01AF, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01B7, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01B8, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01B9, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01BA, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01BB, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01BC, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01BD, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01BE, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01BF, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01C3, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_AISEETHROUGH, OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01C4, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01C5, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01C6, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01C7, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF, 0, 1000)
	glass(0x0100, MODEL_WINDOW, PAD_DISH_01D1, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF, 0, 1000)
	tag(0x80, 6)
	tag(0x81, 6)
	tag(0x82, 6)
	tag(0x83, 6)
	tag(0x43, 1)
	lift(0x0100, MODEL_CI_LIFT, PAD_DISH_0193, OBJFLAG_00000008 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_FORCENOBOUNCE | OBJFLAG_01000000 | OBJFLAG_CANNOT_ACTIVATE, OBJFLAG2_NOFALL | OBJFLAG2_FALLWITHOUTROTATION | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000, 0x0193, 0x0194, -1, -1, 0x00000001, 0x00000003, 0x00000000, 0x00000000, 0x0000071c, 0x0010aaaa, 0x16000000)
	door(0x0100, MODEL_DD_LIFTDOOR, PAD_DISH_015E, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x0000e666, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_FLIP, DOORTYPE_SLIDING, 0x00000000, 0x000001e0, 0x00000000, 0x00000001, 0x00001c00)
	door(0x0100, MODEL_DD_LIFTDOOR, PAD_DISH_015F, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x0000e666, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, 0, DOORTYPE_SLIDING, 0x00000000, 0x000001e0, 0x00000000, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DD_LIFTDOOR, PAD_DISH_0160, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x0000e666, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_FLIP, DOORTYPE_SLIDING, 0x00000000, 0x000001e0, 0x00000000, 0x00000001, 0x00001c00)
	door(0x0100, MODEL_DD_LIFTDOOR, PAD_DISH_0161, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x0000e666, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, 0, DOORTYPE_SLIDING, 0x00000000, 0x000001e0, 0x00000000, 0xffffffff, 0x00000000)
	lift_door(-4, -5, 0)
	lift_door(-4, -6, 0)
	lift_door(-4, -7, 1)
	lift_door(-4, -8, 1)
	tag(0x84, 6)
	tag(0x85, 6)
	tag(0x86, 6)
	tag(0x87, 6)
	tag(0x44, 1)
	lift(0x0100, MODEL_CI_LIFT, PAD_DISH_0195, OBJFLAG_00000008 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_FORCENOBOUNCE | OBJFLAG_01000000 | OBJFLAG_CANNOT_ACTIVATE, OBJFLAG2_NOFALL | OBJFLAG2_FALLWITHOUTROTATION | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000, 0x0195, 0x0196, -1, -1, 0x00000001, 0x00000003, 0x00000000, 0x00000000, 0x0000071c, 0x0010aaaa, 0x16000000)
	door(0x0100, MODEL_DD_LIFTDOOR, PAD_DISH_0164, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x0000e666, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_FLIP, DOORTYPE_SLIDING, 0x00000000, 0x000001e0, 0x00000000, 0x00000001, 0x00001c00)
	door(0x0100, MODEL_DD_LIFTDOOR, PAD_DISH_0165, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x0000e666, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, 0, DOORTYPE_SLIDING, 0x00000000, 0x000001e0, 0x00000000, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DD_LIFTDOOR, PAD_DISH_0162, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x0000e666, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_FLIP, DOORTYPE_SLIDING, 0x00000000, 0x000001e0, 0x00000000, 0x00000001, 0x00001c00)
	door(0x0100, MODEL_DD_LIFTDOOR, PAD_DISH_0163, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x0000e666, 0x00010000, 0x00007fff, 0x00014000, 0x00000666, 0, DOORTYPE_SLIDING, 0x00000000, 0x000001e0, 0x00000000, 0xffffffff, 0x00000000)
	lift_door(-4, -5, 0)
	lift_door(-4, -6, 0)
	lift_door(-4, -7, 1)
	lift_door(-4, -8, 1)
	tag(0x00, 1)
	stdobject(0x0100, MODEL_DD_CHAIR, PAD_DISH_021B, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_DD_DESK, PAD_DISH_021A, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_IMMUNETOGUNFIRE, 0, 1000)
	tag(0x1b, 1)
	singlemonitor(0x0100, MODEL_GOODPC, PAD_DISH_021C, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, OBJFLAG3_INTERACTABLE, 1000, 3)
	tag(0x01, 1)
	stdobject(0x0100, MODEL_DD_CHAIR, PAD_DISH_021F, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, 0, 0, 1000)
	stdobject(0x0100, MODEL_DD_DESK, PAD_DISH_021D, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE, 0, 1000)
	tag(0x10, 1)
	singlemonitor(0x0100, MODEL_GOODPC, PAD_DISH_021E, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR, 0, OBJFLAG3_INTERACTABLE, 1000, 3)
	tag(0x02, 1)
	stdobject(0x00b3, MODEL_DD_CHAIR, PAD_DISH_0220, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, 0, 0, 1000)
	stdobject(0x0100, MODEL_DD_DESK, PAD_DISH_0222, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE, 0, 1000)
	tag(0x0f, 1)
	singlemonitor(0x0100, MODEL_GOODPC, PAD_DISH_0221, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR, 0, OBJFLAG3_INTERACTABLE, 1000, 3)
	tag(0x33, -1)
	tag(0x0d, 1)
	stdobject(0x0100, MODEL_DD_CHAIR, PAD_DISH_0223, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, 0, 0, 1000)
	stdobject(0x0100, MODEL_DD_DESK, PAD_DISH_0225, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE, 0, 1000)
	tag(0x0e, 1)
	singlemonitor(0x0100, MODEL_GOODPC, PAD_DISH_0224, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 3)
	tag(0x7f, 1)
	singlemonitor(0x0100, MODEL_GOODPC, PAD_DISH_022D, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, OBJFLAG3_INTERACTABLE, 1000, 3)
	require_object_holographed(0x0000000e)
	tag(0x05, 18)
	tag(0x06, 18)
	tag(0x07, 18)
	tag(0x08, 18)
	tag(0x09, 18)
	tag(0x0a, 18)
	tag(0x0b, 18)
	tag(0x0c, 18)
	tag(0x11, 18)
	tag(0x12, 18)
	tag(0x13, 18)
	tag(0x14, 18)
	tag(0x15, 18)
	tag(0x16, 18)
	tag(0x17, 18)
	tag(0x18, 18)
	tag(0x19, 18)
	tag(0x1a, 18)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	stdobject(0x0019, MODEL_TARGET, PAD_DISH_00D6, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_INVISIBLE, 0, 1000)
	chr(SPAWNFLAG_NOBLOOD, 0x00, PAD_CARRINGTON_OFFICE, BODY_CARRINGTON, HEAD_CARRINGTON, AILIST_INIT_CARRINGTON, -1, -1, 1000, 4, 0, 0, TEAM_20, SQUADRON_05, -1, 0, 2, 0, 0, 0)
	chr(SPAWNFLAG_NOBLOOD, 0x01, PAD_DISH_00F8, BODY_CIFEMTECH, HEAD_SECRETARY, 0x0420, -1, -1, 1000, 4, 0, 0, TEAM_20, SQUADRON_05, -1, 0, 2, 0, 0, 0)
	chr(SPAWNFLAG_NOBLOOD, 0x02, PAD_DISH_00FA, BODY_CILABTECH, HEAD_CHRIST, 0x0424, -1, -1, 1000, 4, 0, 0, TEAM_20, SQUADRON_05, -1, 0, 2, 0, 0, 0)
	chr(SPAWNFLAG_NOBLOOD, 0x03, PAD_DISH_00F7, BODY_CILABTECH, HEAD_MARK2, 0x0421, -1, -1, 1000, 6, 0, 0, TEAM_20, SQUADRON_05, -1, 0, 2, 0, 0, 0)
	chr(SPAWNFLAG_NOBLOOD, 0x04, PAD_DISH_00F9, BODY_CIFEMTECH, HEAD_SECRETARY, 0x0422, -1, -1, 1000, 6, 0, 0, TEAM_20, SQUADRON_05, -1, 0, 2, 0, 0, 0)
	chr(SPAWNFLAG_NOBLOOD, 0x05, PAD_DISH_00FB, BODY_CILABTECH, HEAD_BRIAN, 0x0423, -1, -1, 1000, 6, 0, 0, TEAM_20, SQUADRON_05, -1, 0, 2, 0, 0, 0)
	chr(SPAWNFLAG_NOBLOOD | SPAWNFLAG_FIXEDHEIGHT, 0x06, PAD_DISH_00FD, BODY_CILABTECH, HEAD_RUSS, 0x0425, -1, -1, 0, 0, CHRFLAG0_COVER_TYPE2 | CHRFLAG0_HEAR_REQUIRE_LOS | CHRFLAG0_CANLOSEGUN, CHRFLAG1_DOINGIDLEANIMATION, TEAM_ENEMY, SQUADRON_0D, 0x01, 0, 0, 2, 0, 0)
	chr(SPAWNFLAG_NOBLOOD | SPAWNFLAG_FIXEDHEIGHT, 0x07, PAD_DISH_00FC, BODY_CILABTECH, HEAD_BEAU1, 0x0426, -1, -1, 0, 0, CHRFLAG0_COVER_TYPE2 | CHRFLAG0_HEAR_REQUIRE_LOS | CHRFLAG0_CANLOSEGUN, CHRFLAG1_DOINGIDLEANIMATION, TEAM_ENEMY, SQUADRON_0D, 0x00, 0, 0, 2, 0, 0)
	chr(SPAWNFLAG_NOBLOOD | SPAWNFLAG_FIXEDHEIGHT, 0x08, PAD_DISH_00FE, BODY_CIFEMTECH, HEAD_SECRETARY, 0x0427, -1, -1, 0, 0, CHRFLAG0_COVER_TYPE2 | CHRFLAG0_HEAR_REQUIRE_LOS | CHRFLAG0_CANLOSEGUN, CHRFLAG1_DOINGIDLEANIMATION, TEAM_ENEMY, SQUADRON_0D, 0x02, 0, 0, 2, 0, 0)
	tag(0x1e, 8)
	tag(0x1f, 8)
	tag(0x20, 8)
	tag(0x21, 8)
	tag(0x22, 8)
	tag(0x23, 8)
	tag(0x24, 8)
	tag(0x25, 8)
	weapon(0x0100, MODEL_CHRWPPK, PAD_DISH_0115, OBJFLAG_00000008 | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_IMMUNETOANTI, 0, WEAPON_LAPTOPGUN)
	weapon(0x0100, MODEL_CHRTT33, PAD_DISH_0116, OBJFLAG_00000008 | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_IMMUNETOANTI, 0, WEAPON_LAPTOPGUN)
	weapon(0x0100, MODEL_CHRSKORPION, PAD_DISH_0117, OBJFLAG_00000008 | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_IMMUNETOANTI, 0, WEAPON_LAPTOPGUN)
	weapon(0x0100, MODEL_CHRKALASH, PAD_DISH_0118, OBJFLAG_00000008 | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_IMMUNETOANTI, 0, WEAPON_LAPTOPGUN)
	weapon(0x0100, MODEL_CHRUZI, PAD_DISH_0119, OBJFLAG_00000008 | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_IMMUNETOANTI, 0, WEAPON_LAPTOPGUN)
	weapon(0x0100, MODEL_CHRMP5K, PAD_DISH_011A, OBJFLAG_00000008 | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_IMMUNETOANTI, 0, WEAPON_LAPTOPGUN)
	weapon(0x0100, MODEL_CHRM16, PAD_DISH_011B, OBJFLAG_00000008 | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_IMMUNETOANTI, 0, WEAPON_LAPTOPGUN)
	weapon(0x0100, MODEL_CHRFNP90, PAD_DISH_011C, OBJFLAG_00000008 | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_IMMUNETOANTI, 0, WEAPON_LAPTOPGUN)
	tag(0x7a, 1)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01C8, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000)
	tag(0x79, 1)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01C9, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000)
	tag(0x78, 1)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01CA, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000)
	tag(0x7e, 1)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01CB, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000)
	tag(0x7b, 1)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01CC, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000)
	tag(0x7c, 1)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01CD, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000)
	tag(0x7d, 1)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01CE, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000)
	tag(0x77, 1)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01CF, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000)
	glass(0x0100, MODEL_DD_WINDOW, PAD_DISH_01D0, OBJFLAG_00000002 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_ORTHOGONAL | OBJFLAG_PATHBLOCKER | OBJFLAG_INVINCIBLE | OBJFLAG_AISEETHROUGH, OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, 0, 1000)
	stdobject(0x0100, MODEL_DD_DESK, PAD_DISH_0229, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE, 0, 1000)
	tag(0x2f, 1)
	weapon(0x0100, MODEL_CHRDATATHIEF, -1, OBJFLAG_00000008 | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_DATAUPLINK)
	stdobject(0x0100, MODEL_DD_DESK, PAD_DISH_0228, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, 0, 0, 1000)
	stdobject(0x0100, MODEL_DD_CHAIR, PAD_DISH_0226, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_IMMUNETOGUNFIRE, 0, 1000)
	tag(0x30, 1)
	singlemonitor(0x0180, MODEL_GOODPC, PAD_DISH_0227, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR, 0, OBJFLAG3_INTERACTABLE, 1000, 3)
	tag(0x2e, 1)
	weapon(0x0180, MODEL_CHRECMMINE, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_ECMMINE)
	tag(0x32, 1)
	multimonitor(0x0140, MODEL_CIHUB, PAD_DISH_0239, OBJFLAG_00000002, 0, OBJFLAG3_INTERACTABLE, 1000, 3, 0, 0, 0)
	tag(0x26, 1)
	weapon(0x0100, MODEL_CHREYESPY, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_EYESPY)
	tag(0x27, 1)
	weapon(0x0180, MODEL_CHRNIGHTSIGHT, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_NIGHTVISION)
	tag(0x34, 1)
	stdobject(0x0100, MODEL_LIGHTSWITCH, PAD_DISH_023A, OBJFLAG_00000002 | OBJFLAG_DEACTIVATED, OBJFLAG2_INVISIBLE, OBJFLAG3_INTERACTABLE, 1000)
	tag(0x28, 1)
	weapon(0x0200, MODEL_CHRDOORDECODER, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_DOORDECODER)
	tag(0x35, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_023B, OBJFLAG_00000002, 0, OBJFLAG3_INTERACTABLE, 1000, 3, 0, 0, 0)
	tag(0x88, 1)
	stdobject(0x0200, MODEL_CHRDOORDECODER, PAD_DISH_0130, OBJFLAG_00000008 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_IMMUNETOANTI | OBJFLAG2_INVISIBLE, 0, 1000)
	tag(0x2c, 1)
	weapon(0x0180, MODEL_RUSSDAR, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_RTRACKER)
	tag(0x36, 1)
	weapon(0x0180, MODEL_MISC_IRSPECS, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_IRSCANNER)
	tag(0x29, 1)
	weapon(0x0180, MODEL_XRAYSPECS, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_XRAYSCANNER)
	tag(0x38, 1)
	multimonitor(0x0099, MODEL_CIHUB, PAD_DISH_023C, OBJFLAG_00000002, 0, OBJFLAG3_INTERACTABLE, 1000, 3, 0, 0, 0)
	tag(0x39, 1)
	multimonitor(0x0099, MODEL_CIHUB, PAD_DISH_023D, OBJFLAG_00000002, 0, OBJFLAG3_INTERACTABLE, 1000, 3, 0, 0, 0)
	tag(0x2a, 1)
	weapon(0x0180, MODEL_CHRBRIEFCASE, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_DISGUISE41)
	tag(0x2b, 1)
	weapon(0x0180, MODEL_MISC_IRSPECS, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_IRSCANNER)
	tag(0x2d, 1)
	weapon(0x0180, MODEL_CHRCLOAKER, -1, OBJFLAG_FALL | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_CLOAKINGDEVICE)
	tag(0x3c, 1)
	weapon(0x0180, MODEL_CHRCLOAKER, 0x0003, OBJFLAG_FALL | OBJFLAG_ASSIGNEDTOCHR | OBJFLAG_UNCOLLECTABLE, OBJFLAG2_INVISIBLE, 0, WEAPON_CLOAKINGDEVICE)
	tag(0x3d, 1)
	door(0x0100, MODEL_DD_GRATE, PAD_DISH_0185, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x005a0000, 0x03e80000, 0x012c0000, 0x012c0000, 0x00030000, DOORFLAG_AUTOMATIC, DOORTYPE_SWINGING, 0x00000040, 0x000001e0, 0x00000000, 0x00000000, 0x00000b00)
	tag(0x3e, 1)
	door(0x0100, MODEL_DEVICESECRETDOOR, PAD_DISH_0186, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH | OBJFLAG_DEACTIVATED | OBJFLAG_DOOR_OPENTOFRONT, 0, 0, 1000, 0x005a0000, 0x03e80000, 0x012c0000, 0x012c0000, 0x00030000, DOORFLAG_AUTOMATIC, DOORTYPE_SWINGING, 0x00000040, 0x000001e0, 0x00000000, 0x00000000, 0x00000b00)
	tag(0x3f, 1)
	door(0x0100, MODEL_DD_GRATE, PAD_DISH_0187, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x005a0000, 0x03e80000, 0x012c0000, 0x012c0000, 0x00030000, DOORFLAG_AUTOMATIC, DOORTYPE_SWINGING, 0x00000040, 0x000001e0, 0x00000000, 0x00000000, 0x00000b00)
	tag(0x40, 1)
	door(0x0100, MODEL_CARRINGTONSECRETDOOR, PAD_DISH_0188, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x005a0000, 0x03e80000, 0x012c0000, 0x012c0000, 0x00030000, DOORFLAG_AUTOMATIC, DOORTYPE_SWINGING, 0x00000040, 0x000001e0, 0x00000000, 0x00000000, 0x00000b00)
	tag(0x3a, 1)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_0189, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	tag(0x3b, 1)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_018A, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	camera(0x00c0, MODEL_CCTV_PD, PAD_DISH_027B, OBJFLAG_00000002 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_DEACTIVATED | OBJFLAG_CAMERA_DISABLED, 0, 0, 400, 0x011f, 0x00000000, 0x00000000, 0x00000000)
	tag(0x41, 1)
	door(0x0100, MODEL_DD_GRATE, PAD_DISH_018B, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_AISEETHROUGH, 0, 0, 1000, 0x0000f333, 0x0000e666, 0x00007fff, 0x00014000, 0x00000666, DOORFLAG_0004 | DOORFLAG_FLIP, DOORTYPE_VERTICAL, 0x00000040, 0x000001e0, 0x00000000, 0x00000000, 0x00000a00)
	tag(0x37, 1)
	door(0x0100, MODEL_SECRETINDOOR, PAD_DISH_0192, OBJFLAG_DEACTIVATED, 0, OBJFLAG3_INFRARED, 1000, 0x005a0000, 0x03e80000, 0x012c0000, 0x012c0000, 0x00030000, 0, DOORTYPE_SWINGING, 0x00000040, 0x000001e0, 0x00000000, 0x00000000, 0x00000b00)
	tag(0x93, 1)
	hover_prop(0x00eb, MODEL_HOVERCRATE1, PAD_DISH_0141, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH | OBJFLAG_DEACTIVATED | OBJFLAG_HOVERPROP_20000000, OBJFLAG2_NOFALL | OBJFLAG2_FALLWITHOUTROTATION | OBJFLAG2_REMOVEWHENDESTROYED | OBJFLAG2_BULLETPROOF | OBJFLAG2_HOVERPROP_80000000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE, 1000, HOVTYPE_CRATE)
	hoverbike(0x0100, MODEL_HOVBIKE, PAD_DISH_01F9, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_NOFALL | OBJFLAG2_FALLWITHOUTROTATION | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_IMMUNETOEXPLOSIONS, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_GEOCYL, 1000)
	tag(0x42, 1)
	stdobject(0x0100, MODEL_DROPSHIP, -1, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_IGNOREROOMCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	door(0x0100, MODEL_CH_SHUTTER1, PAD_DISH_0166, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, OBJFLAG2_AICANNOTUSE, 0, 1000, 0x0000fd70, 0x0000e666, 0x00007fff, 0x00014000, 0x00000222, 0, DOORTYPE_VERTICAL, 0x00000020, 0x00000384, 0x00000000, 0x00000000, 0x00000400)
	door(0x0100, MODEL_CH_SHUTTER1, PAD_DISH_0167, OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000fd70, 0x0000e666, 0x00007fff, 0x00014000, 0x00000222, 0, DOORTYPE_VERTICAL, 0x00000020, 0x00000384, 0x00000000, 0x00000000, 0x00000400)
#if VERSION >= VERSION_NTSC_1_0
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0168, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0169, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016A, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016B, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016C, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016D, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016E, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016F, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0170, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0171, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0172, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0173, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0174, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0175, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0176, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0177, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0178, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0179, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017B, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017C, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017D, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017E, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017F, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0180, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
#else
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0168, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0169, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016A, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016B, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016C, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016D, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016E, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_016F, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0170, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0171, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0172, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0173, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0174, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0175, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0176, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0177, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0178, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0179, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017B, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017C, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017D, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017E, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_017F, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0180, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
#endif
	door(0x0100, MODEL_CH_SHUTTER1, PAD_DISH_0181, OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_AICANNOTUSE, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000222, 0, DOORTYPE_VERTICAL, 0x00000040, 0x00000384, 0x00000000, 0x00000000, 0x00000400)
	door(0x0100, MODEL_CH_SHUTTER1, PAD_DISH_0182, OBJFLAG_IGNOREFLOORCOLOUR, OBJFLAG2_AICANNOTUSE, 0, 1000, 0x0000f333, 0x00010000, 0x00007fff, 0x00014000, 0x00000222, 0, DOORTYPE_VERTICAL, 0x00000040, 0x00000384, 0x00000000, 0x00000000, 0x00000400)
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0183, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0x00000001, 0x00000300)
#if VERSION >= VERSION_NTSC_1_0
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0184, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000000)
#else
	door(0x0100, MODEL_DOOR2_G5, PAD_DISH_0184, OBJFLAG_DEACTIVATED, 0, 0, 1000, 0x0000f333, 0x00010000, 0x0001aaaa, 0x0001aaaa, 0x00000222, DOORFLAG_WINDOWED | DOORFLAG_0004, DOORTYPE_SLIDING, 0x00000000, 0x00000258, 0x012c0320, 0xffffffff, 0x00000300)
#endif
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01D6, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01E1, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01E2, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01E5, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01E6, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01E8, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01E9, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01EA, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01EB, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01EC, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01ED, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01EE, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01EF, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01F0, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01F1, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01F3, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01F4, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01F5, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01F6, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01F7, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01FA, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01FB, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01FC, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01FD, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01FE, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0200, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0201, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0202, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0204, OBJFLAG_FALL | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, 0, 0, 1000)
	tag(0x46, 1)
	singlemonitor(0x0100, MODEL_GOODPC, PAD_DISH_022A, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR, 0, OBJFLAG3_INTERACTABLE, 1000, 3)
	tag(0x45, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_023E, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 3, 0, 0, 0)
	tag(0x47, 1)
	singlemonitor(0x0100, MODEL_GOODPC, PAD_DISH_022B, OBJFLAG_00000008 | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_IGNOREFLOORCOLOUR, 0, OBJFLAG3_INTERACTABLE, 1000, 3)
	tag(0x48, 1)
	multimonitor(0x00cc, MODEL_CIHUB, PAD_DISH_0240, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x49, 1)
	multimonitor(0x00cc, MODEL_CIHUB, PAD_DISH_0241, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x4a, 1)
	multimonitor(0x00cc, MODEL_CIHUB, PAD_DISH_0242, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x4b, 1)
	multimonitor(0x00cc, MODEL_CIHUB, PAD_DISH_0243, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x4c, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_0247, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x4d, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_0246, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x4e, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_0245, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x4f, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_0244, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x54, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_024C, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x55, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_024D, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x56, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_024E, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x57, 1)
	multimonitor(0x0100, MODEL_CIHUB, PAD_DISH_024F, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE, 1000, 20, 0, 0, 0)
	tag(0x58, 15)
	tag(0x59, 15)
	tag(0x5a, 15)
	tag(0x5b, 15)
	tag(0x5c, 15)
	tag(0x5d, 15)
	tag(0x5e, 15)
	tag(0x5f, 15)
	tag(0x60, 15)
	tag(0x61, 15)
	tag(0x62, 15)
	tag(0x63, 15)
	tag(0x64, 15)
	tag(0x73, 15)
	tag(0x74, 15)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0205, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0206, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0207, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0208, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0209, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_020A, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_020B, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_020C, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_020D, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_020E, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01D2, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_01D3, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_020F, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0210, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	stdobject(0x0100, MODEL_A51_CRATE1, PAD_DISH_0211, OBJFLAG_FALL | OBJFLAG_XTOPADBOUNDS | OBJFLAG_YTOPADBOUNDS | OBJFLAG_ZTOPADBOUNDS | OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_INVINCIBLE, OBJFLAG2_DONTPAUSE, 0, 1000)
	tag(0x67, 12)
	tag(0x68, 12)
	tag(0x69, 12)
	tag(0x6a, 12)
	tag(0x6b, 12)
	tag(0x6c, 12)
	tag(0x6d, 12)
	tag(0x6e, 12)
	tag(0x6f, 12)
	tag(0x70, 12)
	tag(0x71, 12)
	tag(0x72, 12)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_027C, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_027D, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_027E, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_027F, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_0280, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_0281, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_0282, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_0283, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_0284, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_0285, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_0286, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	door(0x0100, MODEL_LASDOOR, PAD_DISH_0287, OBJFLAG_00000100 | OBJFLAG_IGNOREFLOORCOLOUR | OBJFLAG_CANNOT_ACTIVATE | OBJFLAG_AISEETHROUGH, OBJFLAG2_DONTPAUSE, 0, 1000, 0x00011999, 0x00011999, 0x7fffffff, 0x7fffffff, 0x7fffffff, DOORFLAG_DAMAGEONCONTACT, DOORTYPE_LASER, 0x00000000, 0x00004650, 0x00000000, 0x00000000, 0x00000000)
	tag(0x65, 1)
	multimonitor(0x00cc, MODEL_CIHUB, PAD_DISH_0250, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE | OBJFLAG3_INTERACTSHORTRANGE, 1000, 20, 0, 0, 0)
	tag(0x66, 1)
	multimonitor(0x00cc, MODEL_CIHUB, PAD_DISH_0251, OBJFLAG_00000002, OBJFLAG2_DONTPAUSE, OBJFLAG3_INTERACTABLE | OBJFLAG3_INTERACTSHORTRANGE, 1000, 20, 0, 0, 0)
	tag(0x8b, 1)
	autogun(0x00a6, MODEL_CI_ROOFGUN, PAD_DISH_0235, OBJFLAG_UPSIDEDOWN, 0, 0, 1000, 0x0075, 0x00005555, 0xffffaaab, 0x00000aaa, 0x00320000)
	tag(0x8c, 1)
	autogun(0x00a6, MODEL_CI_ROOFGUN, PAD_DISH_0234, OBJFLAG_UPSIDEDOWN, 0, 0, 1000, 0x007f, 0x00005555, 0xffffaaab, 0x00000aaa, 0x00320000)
	tag(0x8d, 1)
	autogun(0x00a6, MODEL_CI_ROOFGUN, PAD_DISH_0233, OBJFLAG_UPSIDEDOWN, 0, 0, 1000, 0x0097, 0x00005555, 0xffffaaab, 0x00000aaa, 0x00320000)
	tag(0x8e, 1)
	multimonitor(0x0099, MODEL_CIHUB, PAD_DISH_0236, OBJFLAG_00000002, OBJFLAG2_IMMUNETOANTI, OBJFLAG3_INTERACTABLE, 1000, 3, 3, 3, 0)
	tag(0x8f, 1)
	multimonitor(0x0099, MODEL_CIHUB, PAD_DISH_0237, OBJFLAG_00000002, OBJFLAG2_IMMUNETOANTI, OBJFLAG3_INTERACTABLE, 1000, 3, 3, 3, 0)
	tag(0x90, 1)
	multimonitor(0x0099, MODEL_CIHUB, PAD_DISH_0238, OBJFLAG_00000002, OBJFLAG2_IMMUNETOANTI, OBJFLAG3_INTERACTABLE, 1000, 3, 3, 3, 0)
	endprops
};

/**
 * Wait until seeing player (without cloak) then assign colleague.
 */
u8 func041d_init_collegue_when_sighted[] = {
	restart_timer

	beginloop(0x04)
		if_los_to_target(/*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	yield
	if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, TRUE, /*goto*/ 0x2f)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)

	label(0x2f)
	goto_first(0x04)

	endlist
};

u8 func041e_colleague[] = {
	set_returnlist(CHR_SELF, AILIST_COLLEAGUE)
	if_alertness(1, OPERATOR_LESS_THAN, /*goto*/ 0x04)
	if_alertness(2, OPERATOR_LESS_THAN, /*goto*/ 0x7c)
	if_alertness(3, OPERATOR_LESS_THAN, /*goto*/ 0x7d)

	beginloop(0x04)
		// Wait until player in sight and not doing idle animations already
		if_can_see_target(/*goto*/ 0x2f)
		if_chr_idle(/*goto*/ 0x06)
		if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, FALSE, BANK_1, /*goto*/ 0x7f)
		chr_do_animation(ANIM_SITTING_DORMANT, 0, -1, CHRANIMFLAG_PAUSEATEND | CHRANIMFLAG_SLOWUPDATE, 0, CHR_SELF, 2)
		reloop(0x04)

		// Player not in sight - 2 in 255 chance of doing a bored animation
		label(0x7f)
		call_rng
		if_rand_gt(1, /*goto*/ 0x06)
		set_ailist(CHR_SELF, GAILIST_DO_BORED_ANIMATION)
		label(0x06)
		reloop(0x04)

		// Player is in sight - prepare to talk
		label(0x2f)
		restart_timer
		label(0x08)
		if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, TRUE, BANK_1, /*goto*/ 0x06)
		try_face_entity(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x09)

		beginloop(0x09)
			if_target_in_fov_left(10, /*goto*/ 0x06)
			if_timer_gt(60, /*goto*/ 0x06)
		endloop(0x09)

		label(0x06)
		if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, TRUE, BANK_1, /*goto*/ 0x7f)
		do_preset_animation(PRESETANIM_TALK3)
		goto_next(0x2f)

		label(0x7f)
		chr_do_animation(ANIM_SITTING_0265, 0, -1, CHRANIMFLAG_PAUSEATEND | CHRANIMFLAG_SLOWUPDATE, 0, CHR_SELF, 2)
		label(0x2f)
		play_cistaff_quip(CIQUIP_GREETING, CHANNEL_6)
		restart_timer

		beginloop(0x57)
			if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
		endloop(0x57)

		label(0x06)
		if_morale_lt(6, /*goto*/ 0x06)
		goto_next(0x7e)

		label(0x06)
		restart_timer
		stop_chr
		try_face_entity(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x59)

		beginloop(0x59)
			if_can_see_target(/*goto*/ 0x06)
		endloop(0x59)

		label(0x06)
		if_timer_gt(120, /*goto*/ 0x06)
		goto_first(0x59)

		label(0x06)
		if_within_targets_fovx_by_angle(20, /*goto*/ 0x06)
		goto_first(0x59)

		label(0x06)
		do_preset_animation(PRESETANIM_TALKRANDOM)
		label(0x06)
		play_cistaff_quip(CIQUIP_MAIN, CHANNEL_6)
		restart_timer

		beginloop(0x5b)
			if_sound_finished(CHANNEL_6, /*goto*/ 0x7e)
		endloop(0x5b)

		label(0x7e)
		if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, TRUE, BANK_1, /*goto*/ 0x7f)
		stop_chr
		label(0x7f)
		set_alertness(1)
		label(0x7c)
		restart_timer

		beginloop(0x0a)
			if_timer_lt(600, /*goto*/ 0x2f)
			if_can_see_target(/*goto*/ 0x06)
			goto_next(0x2f)

			label(0x06)
			if_within_targets_fovx_by_angle(20, /*goto*/ 0x30)
			label(0x2f)
			if_chr_idle(/*goto*/ 0x06)
			if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, FALSE, BANK_1, /*goto*/ 0x7f)
			set_ailist(CHR_SELF, GAILIST_DO_SITTING_ANIMATION)
			reloop(0x04)

			label(0x7f)
			call_rng
			if_rand_gt(1, /*goto*/ 0x06)
			set_ailist(CHR_SELF, GAILIST_DO_BORED_ANIMATION)
			label(0x06)
		endloop(0x0a)

		label(0x30)
		if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, TRUE, BANK_1, /*goto*/ 0x7f)
		do_preset_animation(PRESETANIM_TALKRANDOM)
		goto_next(0x06)

		label(0x7f)
		chr_do_animation(ANIM_SITTING_0265, 0, -1, CHRANIMFLAG_PAUSEATEND | CHRANIMFLAG_SLOWUPDATE, 0, CHR_SELF, 2)
		label(0x06)
		play_cistaff_quip(CIQUIP_ANNOYED, CHANNEL_6)
		restart_timer

		beginloop(0x5c)
			if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
		endloop(0x5c)

		label(0x06)
		if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, TRUE, BANK_1, /*goto*/ 0x7f)
		stop_chr
		label(0x7f)
		set_alertness(2)
		label(0x7d)
		yield
		if_chr_idle(/*goto*/ 0x06)
		if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, FALSE, BANK_1, /*goto*/ 0x7f)
		set_ailist(CHR_SELF, GAILIST_DO_SITTING_ANIMATION)
	endloop(0x04)

	label(0x7f)
	call_rng
	if_rand_gt(1, /*goto*/ 0x06)
	set_ailist(CHR_SELF, GAILIST_DO_BORED_ANIMATION)

	label(0x06)
	goto_first(0x7d)

	endlist
};

u8 func041f_colleague1[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(0)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func0420_colleague2[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(1)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func0421_colleague3[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(2)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func0422_colleague4[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(3)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func0423_colleague5[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(4)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func0424_colleague6[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(5)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func0425_colleague7[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(6)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func0426_colleague8[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(7)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func0427_colleague9[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(8)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func0428_colleague10[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	set_morale(9)
	set_ailist(CHR_SELF, AILIST_COLLEAGUE)
	endlist
};

u8 func1001_set_jo_team[] = {
	yield
	set_chr_team(CHR_BOND, TEAM_32)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1002_devicetraining_camspy[] = {
	label(0x80)
	beginloop(0x0f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CAMSPY, TRUE, /*goto*/ 0x81)
	endloop(0x0f)

	label(0x81)
	disable_object(0x0e)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	enable_object(OBJ_CAMSPY)
	move_object_to_pad(OBJ_CAMSPY, PAD_DISH_011D)
	unset_object_flag(OBJ_CAMSPY, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(OBJ_CAMSPY, OBJFLAG2_INVISIBLE)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)
	yield
	enable_object(0x0e)

	label(0x8c)
		remove_hudmsgs
		show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_020) // "Collect CamSpy from table to begin."
		restart_timer

		beginloop(0x86)
			if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
			if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
			if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
			if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
			goto_next(0x59)
			label(0x57)
			set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
			label(0x59)
			if_chr_has_object(CHR_BOND, OBJ_CAMSPY, /*goto*/ 0x2f)
			if_timer_gt(1200, /*goto*/ 0x06)
		endloop(0x86)

		label(0x06)
	goto_first(0x8c)

	label(0x2f)
	label(0x8d)
		remove_hudmsgs
		if_chr_weapon_equipped(CHR_BOND, WEAPON_EYESPY, /*goto*/ 0x2f)
		show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_057) // "Select the CamSpy. - Hold A Button. - Use Control Stick to change selection. - Highlight CamSpy and release A Button."
		restart_timer

		beginloop(0x8e)
			if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
			if_player_using_device(CHR_BOND, WEAPON_EYESPY, /*goto*/ 0x2f)
			if_timer_gt(1200, /*goto*/ 0x06)
		endloop(0x8e)

		label(0x06)
	goto_first(0x8d)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_021) // "Locate Info Room PC and holograph it."

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_door_state(0x31, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x8a, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x89, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_training_pc_holographed(/*goto*/ 0x09)
	endloop(0x82)

	label(0x09)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_022) // "Info Room PC successfully holographed."
	restart_timer

	beginloop(0x0c)
		if_timer_gt(240, /*goto*/ 0x83)
	endloop(0x0c)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	dprint 'd','o','n','e',0,
	yield
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	set_savefile_flag(GAMEFILEFLAG_CI_CAMSPY_DONE)
	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
	remove_hudmsgs
	disable_object(OBJ_CAMSPY)
	goto_first(0x0f)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1003_devicetraining_nightvision[] = {
	label(0x80)

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_NIGHTVISION, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	set_lights_state(0x0030, LIGHTOP_SET, 0, 0, 0)
	set_lights_state(0x002e, LIGHTOP_SET, 0, 0, 0)
	set_lights_state(0x002f, LIGHTOP_SET, 0, 0, 0)
	set_lights_state(0x0020, LIGHTOP_SET, 0, 0, 0)
	set_lights_state(0x0024, LIGHTOP_SET, 0, 0, 0)
	set_lights_state(0x0025, LIGHTOP_SET, 0, 0, 0)
	set_lights_state(0x0026, LIGHTOP_SET, 0, 0, 0)
	set_lights_state(0x0022, LIGHTOP_SET, 0, 0, 0)
	set_stage_flag(STAGEFLAG_IN_TRAINING)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	enable_object(0x27)
	move_object_to_pad(0x27, PAD_DISH_011D)
	unset_object_flag(0x27, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x27, OBJFLAG2_INVISIBLE)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)

	label(0x8c)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_008) // "Collect Night Vision from table to begin."
	restart_timer

	beginloop(0x86)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_has_object(CHR_BOND, 0x27, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x86)

	label(0x06)
	goto_first(0x8c)

	label(0x2f)
	label(0x8d)
	remove_hudmsgs
	if_chr_weapon_equipped(CHR_BOND, WEAPON_NIGHTVISION, /*goto*/ 0x2f)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_058) // "Select the Night Vision. - Hold A Button. - Use Control Stick to change selection. - Highlight Night Vision and release A Button."
	restart_timer

	beginloop(0x8e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_player_using_device(CHR_BOND, WEAPON_NIGHTVISION, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x8e)

	label(0x06)
	goto_first(0x8d)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_009) // "Activate the Night Vision. Locate the light switch. Turn the lights back on."

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_activated_object(CHR_ANY, OBJ_LIGHTSWITCH, /*goto*/ 0x2f)
	endloop(0x82)

	label(0x2f)
#if VERSION >= VERSION_NTSC_1_0
	play_sound(SFX_PRESS_SWITCH, -1)
	set_lights_state(0x0030, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x002e, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x002f, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0020, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0024, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0025, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0026, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0022, LIGHTOP_SET, 255, 0, 0)
#endif
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_023) // "Lights have been reactivated."
	restart_timer

	beginloop(0x0d)
		if_timer_gt(240, /*goto*/ 0x83)
	endloop(0x0d)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_NIGHTVISION_DONE)
	dprint 'd','o','n','e',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	set_lights_state(0x0030, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x002e, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x002f, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0020, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0024, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0025, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0026, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0022, LIGHTOP_SET, 255, 0, 0)
	yield
	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	remove_hudmsgs
	disable_object(0x27)

	beginloop(0x59)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_NIGHTVISION, FALSE, /*goto*/ 0x2f)
	endloop(0x59)

	label(0x2f)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1004_devicetraining_doordecoder[] = {
	label(0x80)

	beginloop(0x0f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_DOORDECODER, TRUE, /*goto*/ 0x81)
	endloop(0x0f)

	label(0x81)
	set_object_flag2(0x88, OBJFLAG2_INVISIBLE)
	set_stage_flag(STAGEFLAG_IN_TRAINING)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	enable_object(0x28)
	move_object_to_pad(0x28, PAD_DISH_011D)
	unset_object_flag(0x28, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x28, OBJFLAG2_INVISIBLE)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)
	label(0x8c)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_024) // "Collect Door Decoder from table to begin."
	restart_timer

	beginloop(0x86)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_has_object(CHR_BOND, 0x28, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x86)

	label(0x06)
	goto_first(0x8c)

	label(0x2f)
	label(0x8d)
	remove_hudmsgs
	if_chr_weapon_equipped(CHR_BOND, WEAPON_DOORDECODER, /*goto*/ 0x2f)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_059) // "Select the Door Decoder. - Hold A Button. - Use Control Stick to change selection. - Highlight Door Decoder and release A Button."
	restart_timer

	beginloop(0x8e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_weapon_equipped(CHR_BOND, WEAPON_DOORDECODER, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x8e)

	label(0x06)
	goto_first(0x8d)

	label(0x2f)
	if_chr_activated_object(CHR_BOND, 0x35, /*goto*/ 0x2f)
	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_025) // "Use Decoder on door pad to unlock it."

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_door_state(0x31, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x8a, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x89, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_chr_activated_object(CHR_BOND, 0x35, /*goto*/ 0x09)
	endloop(0x82)

	label(0x09)
	if_chr_weapon_equipped(CHR_BOND, WEAPON_DOORDECODER, /*goto*/ 0x06)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_026) // "You need to be holding the Door Decoder."
	restart_timer

	beginloop(0x0e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(60, /*goto*/ 0x2f)
	endloop(0x0e)

	label(0x2f)
	goto_first(0x82)

	label(0x06)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_027) // "Decoder attached. Initiating cracking routines..."
	unset_object_flag2(0x88, OBJFLAG2_INVISIBLE)
	assign_sound(SFX_8144, CHANNEL_1)
	play_repeating_sound_from_object(CHANNEL_1, 0x35, 1, 300, 400)
	restart_timer

	beginloop(0x0c)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x2f)
	endloop(0x0c)

	label(0x2f)
	mute_channel(CHANNEL_1)
	assign_sound(SFX_8145, CHANNEL_1)
	set_object_sound_playing(CHANNEL_1, 0x35, TRUE)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_028) // "Decoding complete. Door has been unlocked."
	unlock_door(0x41, 0x40)
	restart_timer

	beginloop(0x0d)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x83)
	endloop(0x0d)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_DOORDECODER_DONE)
	dprint 'd','o','n','e',0,
	yield
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	unset_object_flag2(0x88, OBJFLAG2_INVISIBLE)
	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
	mute_channel(CHANNEL_1)
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	remove_hudmsgs
	disable_object(0x28)
	goto_first(0x0f)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1005_devicetraining_xray[] = {
	label(0x80)
	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_XRAY, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	dprint 't','r','a','i','n','i','n','g',0,
	enable_object(0x29)
	move_object_to_pad(0x29, PAD_DISH_011D)
	unset_object_flag(0x29, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x29, OBJFLAG2_INVISIBLE)
	unset_object_flag2(0x38, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x39, OBJFLAG2_IMMUNETOANTI)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)
	if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
	goto_next(0x59)

	label(0x57)
	set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	label(0x59)
	label(0x8c)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_035) // "Collect X-Ray Scanner from table to begin."
	restart_timer

	beginloop(0x86)
		if_player_using_device(CHR_BOND, WEAPON_XRAYSCANNER, /*goto*/ 0x2f)
		set_object_flag(0x38, OBJFLAG_CANNOT_ACTIVATE)
		set_object_flag(0x39, OBJFLAG_CANNOT_ACTIVATE)
		goto_next(0x30)

		label(0x2f)
		unset_object_flag(0x38, OBJFLAG_CANNOT_ACTIVATE)
		unset_object_flag(0x39, OBJFLAG_CANNOT_ACTIVATE)
		label(0x30)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_has_object(CHR_BOND, 0x29, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x86)

	label(0x06)
	goto_first(0x8c)

	label(0x8d)
	remove_hudmsgs
	if_chr_weapon_equipped(CHR_BOND, WEAPON_XRAYSCANNER, /*goto*/ 0x2f)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_060) // "Select the X-Ray Scanner. - Hold A Button. - Use Control Stick to change selection. - Highlight X-Ray Scanner and release A Button."
	restart_timer

	beginloop(0x8e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_player_using_device(CHR_BOND, WEAPON_XRAYSCANNER, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x8e)

	label(0x06)
	goto_first(0x8d)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_036) // "Find hidden switches to shut down laser grid."

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_player_using_device(CHR_BOND, WEAPON_XRAYSCANNER, /*goto*/ 0x2f)
		set_object_flag(0x38, OBJFLAG_CANNOT_ACTIVATE)
		set_object_flag(0x39, OBJFLAG_CANNOT_ACTIVATE)
		goto_next(0x30)

		label(0x2f)
		unset_object_flag(0x38, OBJFLAG_CANNOT_ACTIVATE)
		unset_object_flag(0x39, OBJFLAG_CANNOT_ACTIVATE)
		label(0x30)
		if_chr_activated_object(CHR_BOND, 0x38, /*goto*/ 0x5b)
		if_chr_activated_object(CHR_BOND, 0x39, /*goto*/ 0x5c)
	endloop(0x82)

	label(0x5b)
	if_object_flag2(0x38, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x87)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_041) // "Laser Grid 1 has been deactivated."
	set_object_image(0x38, 0, TVCMDLIST_12)
	set_object_flag2(0x38, OBJFLAG2_IMMUNETOANTI)
	open_door(0x3a)
	label(0x87)
	restart_timer

	beginloop(0x89)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x85)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x85)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x85)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x89)

	label(0x5c)
	if_object_flag2(0x39, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x88)
	set_object_image(0x39, 0, TVCMDLIST_12)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_042) // "Laser Grid 2 has been deactivated."
	set_object_flag2(0x39, OBJFLAG2_IMMUNETOANTI)
	open_door(0x3b)
	label(0x88)
	restart_timer

	beginloop(0x8a)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x8a)

	label(0x8b)
	disable_object(0x3a)
	goto_next(0x06)

	label(0x07)
	disable_object(0x3b)
	goto_next(0x06)

	label(0x06)
	if_object_flag2(0x38, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_first(0x82)

	label(0x2f)
	if_object_flag2(0x39, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_first(0x82)

	label(0x09)
	restart_timer

	beginloop(0x5b)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x5b)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_037) // "All laser grids have been deactivated."
	restart_timer

	beginloop(0x0e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x83)
	endloop(0x0e)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_XRAY_DONE)
	dprint 'd','o','n','e',0,
	yield
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	remove_hudmsgs
	disable_object(0x29)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1006_devicetraining_disguise[] = {
	label(0x80)
	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_DISGUISE, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	unset_chr_hiddenflag(CHR_BOND, CHRHFLAG_DISGUISED)
	unset_stage_flag(STAGEFLAG_DISGUISE_FAILED)
	unset_stage_flag(STAGEFLAG_DISGUISE_COMPLETE)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	dprint 't','r','a','i','n','i','n','g',0,
	enable_object(0x2a)
	move_object_to_pad(0x2a, PAD_DISH_011D)
	unset_object_flag(0x2a, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x2a, OBJFLAG2_INVISIBLE)
	set_ailist(0x03, AILIST_GRIMSHAW_DISGUISE)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)
	if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
	goto_next(0x59)

	label(0x57)
	set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	label(0x59)
	label(0x8c)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_038) // "Collect Disguise from table to begin."
	restart_timer

	beginloop(0x86)
		if_stage_flag_eq(STAGEFLAG_DISGUISE_FAILED, TRUE, /*goto*/ 0x0a)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)
		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_has_object(CHR_BOND, 0x2a, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x86)

	label(0x06)
	goto_first(0x8c)

	label(0x2f)
	label(0x8d)
	remove_hudmsgs
	if_chr_has_hiddenflag(CHR_BOND, CHRHFLAG_DISGUISED, /*goto*/ 0x2f)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_061) // "Select the Disguise. - Hold A Button. - Use Control Stick to change selection. - Highlight Disguise and release A Button."
	restart_timer

	beginloop(0x8e)
		if_stage_flag_eq(STAGEFLAG_DISGUISE_FAILED, TRUE, /*goto*/ 0x0a)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_has_hiddenflag(CHR_BOND, CHRHFLAG_DISGUISED, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x8e)

	label(0x06)
	goto_first(0x8d)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_039) // "Fool someone into giving you Cloaking Device."

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_door_state(0x31, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x8a, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x89, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_stage_flag_eq(STAGEFLAG_DISGUISE_COMPLETE, TRUE, /*goto*/ 0x09)
		if_stage_flag_eq(STAGEFLAG_DISGUISE_FAILED, TRUE, /*goto*/ 0x0a)
	endloop(0x82)

	label(0x09)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_040) // "Cloaking Device successfully retrieved."
	restart_timer

	beginloop(0x0e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x83)
	endloop(0x0e)

	label(0x0a)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_047) // "You're meant to use the Disguise, remember?"
	restart_timer

	beginloop(0x0f)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x85)
	endloop(0x0f)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_DISGUISE_DONE)
	dprint 'd','o','n','e',0,
	yield
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	remove_hudmsgs
	disable_object(0x2a)

	beginloop(0x6d)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_DISGUISE, FALSE, /*goto*/ 0x2f)
	endloop(0x6d)

	label(0x2f)
	set_ailist(0x03, AILIST_INIT_COLLEAGUE_WHEN_SIGHTED)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1007_devicetrainign_ir[] = {
	label(0x80)
	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_IR, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	if_chr_activated_object(CHR_BOND, 0x37, /*goto*/ 0x2f)
	label(0x2f)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	dprint 't','r','a','i','n','i','n','g',0,
	enable_object(0x2b)
	move_object_to_pad(0x2b, PAD_DISH_011D)
	unset_object_flag(0x2b, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x2b, OBJFLAG2_INVISIBLE)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)
	if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
	goto_next(0x59)

	label(0x57)
	set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	label(0x59)
	label(0x8c)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_032) // "Collect IR Scanner from table to begin."
	restart_timer

	beginloop(0x86)
		if_player_using_device(CHR_BOND, WEAPON_IRSCANNER, /*goto*/ 0x2f)
		set_object_flag(0x37, OBJFLAG_CANNOT_ACTIVATE)
		goto_next(0x30)
		label(0x2f)
		unset_object_flag(0x37, OBJFLAG_CANNOT_ACTIVATE)
		label(0x30)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)
		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_has_object(CHR_BOND, 0x2b, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x86)

	label(0x06)
	goto_first(0x8c)

	label(0x2f)
	label(0x8d)
	remove_hudmsgs
	if_player_using_device(CHR_BOND, WEAPON_IRSCANNER, /*goto*/ 0x2f)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_062) // "Select the IR Scanner. - Hold A Button. - Use Control Stick to change selection. - Highlight IR Scanner and release A Button."
	restart_timer

	beginloop(0x8e)
		if_player_using_device(CHR_BOND, WEAPON_IRSCANNER, /*goto*/ 0x2f)
		set_object_flag(0x37, OBJFLAG_CANNOT_ACTIVATE)
		goto_next(0x30)

		label(0x2f)
		unset_object_flag(0x37, OBJFLAG_CANNOT_ACTIVATE)
		label(0x30)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_player_using_device(CHR_BOND, WEAPON_IRSCANNER, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x8e)

	label(0x06)
	goto_first(0x8d)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_033) // "Locate secret door using IR Scanner."

	beginloop(0x82)
		if_player_using_device(CHR_BOND, WEAPON_IRSCANNER, /*goto*/ 0x2f)
		set_object_flag(0x37, OBJFLAG_CANNOT_ACTIVATE)
		goto_next(0x30)
		label(0x2f)
		unset_object_flag(0x37, OBJFLAG_CANNOT_ACTIVATE)
		label(0x30)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_door_state(0x31, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x8a, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x89, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_chr_activated_object(CHR_BOND, 0x37, /*goto*/ 0x09)
	endloop(0x82)

	label(0x09)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_034) // "Secret door has been successfully located."
	restart_timer

	beginloop(0x0e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x83)
	endloop(0x0e)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_IR_DONE)
	dprint 'd','o','n','e',0,
	yield
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	remove_hudmsgs
	disable_object(0x2b)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1008_devicetraining_rtracker[] = {
	label(0x80)
	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_RTRACKER, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	dprint 't','r','a','i','n','i','n','g',0,
	enable_object(0x2c)
	move_object_to_pad(0x2c, PAD_DISH_011D)
	unset_object_flag(0x2c, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x2c, OBJFLAG2_INVISIBLE)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)
	if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
	goto_next(0x59)

	label(0x57)
	set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	label(0x59)
	label(0x8c)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_029) // "Collect Tracker from table to begin."
	restart_timer

	beginloop(0x86)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_has_object(CHR_BOND, 0x2c, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x86)

	label(0x06)
	goto_first(0x8c)

	label(0x2f)
	label(0x8d)
	remove_hudmsgs
	if_player_using_device(CHR_BOND, WEAPON_RTRACKER, /*goto*/ 0x2f)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_063) // "Select the Tracker. - Hold A Button. - Use Control Stick to change selection. - Highlight Tracker and release A Button."
	restart_timer

	beginloop(0x8e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_player_using_device(CHR_BOND, WEAPON_RTRACKER, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x8e)

	label(0x06)
	goto_first(0x8d)

	label(0x2f)
	unset_object_flag(0x36, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x36, OBJFLAG2_INVISIBLE)
	enable_object(0x36)
	move_object_to_pad(0x36, PAD_DISH_011E)
	set_object_flag3(0x36, OBJFLAG3_RTRACKED_YELLOW)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_030) // "Locate IR Scanner using Tracker."

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_door_state(0x31, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x8a, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x89, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_chr_has_object(CHR_BOND, 0x36, /*goto*/ 0x09)
	endloop(0x82)

	label(0x09)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_031) // "IR Scanner has been successfully located."
	restart_timer

	beginloop(0x0e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x83)
	endloop(0x0e)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_RTRACKER_DONE)
	dprint 'd','o','n','e',0,
	yield
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	remove_hudmsgs
	disable_object(0x2c)
	disable_object(0x36)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1009_devicetraining_cloak[] = {
	label(0x80)
	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	deactivate_alarm
	unset_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	dprint 't','r','a','i','n','i','n','g',0,
	restart_timer
	enable_object(0x2d)
	move_object_to_pad(0x2d, PAD_DISH_011D)
	unset_stage_flag(STAGEFLAG_CLOAK_FAILED)
	unset_stage_flag(STAGEFLAG_CLOAK_COMPLETE)
	unset_object_flag(0x2d, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x2d, OBJFLAG2_INVISIBLE)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)
	if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
	goto_next(0x59)

	label(0x57)
	set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	label(0x59)
	label(0x8c)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_051) // "Collect Cloaking Device from table to begin."
	restart_timer

	beginloop(0x86)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_stage_flag_eq(STAGEFLAG_CLOAK_COMPLETE, TRUE, /*goto*/ 0x09)
		if_stage_flag_eq(STAGEFLAG_CLOAK_FAILED, TRUE, /*goto*/ 0x0a)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_has_object(CHR_BOND, 0x2d, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x86)

	label(0x06)
	goto_first(0x8c)

	label(0x2f)
	set_ailist(CHR_CARRINGTON, AILIST_CARRINGTON_CLOAK)
	label(0x8d)
	remove_hudmsgs
	if_player_using_device(CHR_BOND, WEAPON_CLOAKINGDEVICE, /*goto*/ 0x2f)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_064) // "Select the Cloaking Device. - Hold A Button. - Use Control Stick to change selection. - Highlight Device and release A Button."
	restart_timer

	beginloop(0x8e)
		if_stage_flag_eq(STAGEFLAG_CLOAK_COMPLETE, TRUE, /*goto*/ 0x09)
		if_stage_flag_eq(STAGEFLAG_CLOAK_FAILED, TRUE, /*goto*/ 0x0a)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_player_using_device(CHR_BOND, WEAPON_CLOAKINGDEVICE, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x8e)

	label(0x06)
	goto_first(0x8d)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_052) // "Use Cloaking Device and locate Carrington."

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_door_state(0x31, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x8a, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_door_state(0x89, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x85)
		if_stage_flag_eq(STAGEFLAG_CLOAK_COMPLETE, TRUE, /*goto*/ 0x09)
		if_stage_flag_eq(STAGEFLAG_CLOAK_FAILED, TRUE, /*goto*/ 0x0a)
	endloop(0x82)

	label(0x09)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_054) // "Mission complete - Device Training passed!"
	restart_timer

	beginloop(0x0e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)
		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x83)
	endloop(0x0e)

	label(0x0a)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_055) // "Mission failed - you have been detected."
	restart_timer

	beginloop(0x0f)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x85)
	endloop(0x0f)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_CLOAK_DONE)
	dprint 'd','o','n','e',0,
	yield
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	remove_hudmsgs
	disable_object(0x2d)

	beginloop(0x5c)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, FALSE, /*goto*/ 0x2f)
	endloop(0x5c)

	label(0x2f)
	set_ailist(CHR_CARRINGTON, AILIST_INIT_COLLEAGUE_WHEN_SIGHTED)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func100a_devicetraining_ecmmine[] = {
	label(0x80)
	beginloop(0x0f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_ECMMINE, TRUE, /*goto*/ 0x81)
	endloop(0x0f)

	label(0x81)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	enable_object(0x2e)
	move_object_to_pad(0x2e, PAD_DISH_011D)
	unset_object_flag(0x2e, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x2e, OBJFLAG2_INVISIBLE)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)
	if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
	goto_next(0x59)

	label(0x57)
	set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	label(0x59)
	label(0x8c)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_016) // "Collect ECM Mine from table to begin."
	restart_timer

	beginloop(0x86)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_has_object(CHR_BOND, 0x2e, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x86)

	label(0x06)
	goto_first(0x8c)

	label(0x2f)
	label(0x8d)
	remove_hudmsgs
	if_chr_weapon_equipped(CHR_BOND, WEAPON_ECMMINE, /*goto*/ 0x2f)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_065) // "Select the ECM Mine. - Hold A Button. - Use Control Stick to change selection. - Highlight ECM Mine and release A Button."
	restart_timer

	beginloop(0x8e)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_weapon_equipped(CHR_BOND, WEAPON_ECMMINE, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x8e)

	label(0x06)
	goto_first(0x8d)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_017) // "Locate Hub and throw ECM Mine onto Hub."

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_ammo_quantity_lt(CHR_BOND, AMMOTYPE_ECM_MINE, 1, /*goto*/ 0x2f)
	endloop(0x82)

	label(0x2f)
	yield
	yield
	yield
	yield
	yield
	if_weapon_thrown(WEAPON_ECMMINE, /*goto*/ 0x06)
	goto_first(0x82)

	label(0x06)
	restart_timer

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_weapon_thrown_on_object(WEAPON_ECMMINE, 0x32, /*goto*/ 0x09)
		if_timer_gt(120, /*goto*/ 0x0a)
	endloop(0x08)

	label(0x09)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_019) // "ECM Mine has been placed correctly."
	restart_timer

	beginloop(0x0c)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_timer_gt(240, /*goto*/ 0x83)
	endloop(0x0c)

	label(0x0a)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_018) // "ECM Mine has been placed incorrectly."
	restart_timer

	beginloop(0x0d)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_timer_gt(240, /*goto*/ 0x85)
	endloop(0x0d)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_ECMMINE_DONE)
	dprint 'd','o','n','e',0,
	yield
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	remove_hudmsgs
	disable_object(0x2e)
	goto_first(0x0f)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func100b_devicetraining_uplink[] = {
	label(0x80)
	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_UPLINK, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	lock_door(0x31, 0x40)
	lock_door(0x8a, 0x40)
	lock_door(0x89, 0x40)
	unset_stage_flag(STAGEFLAG_DEVICE_ABORTING)
	unset_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	unset_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	enable_object(0x2f)
	move_object_to_pad(0x2f, PAD_DISH_0131)
	unset_object_flag(0x2f, OBJFLAG_UNCOLLECTABLE)
	unset_object_flag2(0x2f, OBJFLAG2_INVISIBLE)
	dprint 't','r','a','i','n','i','n','g',0,
	close_door(0x31)
	close_door(0x8a)
	close_door(0x89)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x8c)
	if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x8c)
	if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x8c)
	label(0x8c)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_010) // "Collect Data Uplink from table to begin."
	restart_timer

	beginloop(0x86)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)
		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_chr_has_object(CHR_BOND, 0x2f, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x86)

	label(0x06)
	goto_first(0x8c)

	label(0x2f)
	label(0x8d)
	remove_hudmsgs
	if_chr_weapon_equipped(CHR_BOND, WEAPON_DATAUPLINK, /*goto*/ 0x2f)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_056) // "Select the Uplink. - Hold A Button. - Use Control Stick to change selection. - Highlight Data Uplink and release A Button."
	restart_timer

	beginloop(0x8e)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)
		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_weapon_equipped(CHR_BOND, WEAPON_DATAUPLINK, /*goto*/ 0x2f)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x8e)

	label(0x06)
	goto_first(0x8d)

	label(0x2f)
	if_chr_activated_object(CHR_BOND, 0x30, /*goto*/ 0x2f)
	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_011) // "Stand next to the terminal and use the Uplink."

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x30, /*goto*/ 0x2f)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
	endloop(0x82)

	label(0x2f)
	if_chr_weapon_equipped(CHR_BOND, WEAPON_DATAUPLINK, /*goto*/ 0x2f)
	play_sound(SFX_8116, -1)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_012) // "You need to be holding the Data Uplink."
	goto_first(0x82)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_013) // "Connection established..."
	restart_timer

	label(0x08)
	yield
	if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
	if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
	goto_next(0x59)

	label(0x57)
	set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	label(0x59)
	assign_sound(SFX_01BF, CHANNEL_5)
	set_object_sound_playing(CHANNEL_5, 0x30, TRUE)
	label(0x14)
	yield
	if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
	if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
	if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
	goto_next(0x59)

	label(0x57)
	set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	label(0x59)
	if_timer_gt(400, /*goto*/ 0x06)
	if_chr_distance_to_pad_gt(CHR_BOND, 400, PAD_DISH_0227, /*goto*/ 0x09)
	if_chr_weapon_equipped(CHR_BOND, WEAPON_DATAUPLINK, /*goto*/ 0x2f)
	goto_first(0x09)

	label(0x2f)
	goto_first(0x14)

	label(0x06)
	restart_timer
	mute_channel(CHANNEL_5)
	assign_sound(SFX_01C1, CHANNEL_7)
	set_object_sound_playing(CHANNEL_7, 0x30, TRUE)
	remove_hudmsgs
	show_hudmsg(CHR_TARGET, L_DISH_014) // "Terminal has been successfully hacked."

	beginloop(0x15)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(240, /*goto*/ 0x06)
	endloop(0x15)

	label(0x06)
	goto_next(0x83)

	label(0x09)
	remove_hudmsgs
	show_hudmsg(CHR_BOND, L_DISH_015) // "Connection broken - too far from PC."
	mute_channel(CHANNEL_5)
	assign_sound(SFX_01C0, CHANNEL_6)
	set_object_sound_playing(CHANNEL_6, 0x30, TRUE)
	restart_timer

	beginloop(0x16)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x90)
		if_chr_activated_object(CHR_BOND, 0x31, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x8a, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x89, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(120, /*goto*/ 0x06)
	endloop(0x16)

	label(0x06)
	mute_channel(CHANNEL_6)
	goto_first(0x82)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_UPLINK_DONE)
	dprint 'd','o','n','e',0,
	set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_SUCCESS)
	yield
	goto_next(0x84)

	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
	unlock_door(0x31, 0x40)
	unlock_door(0x8a, 0x40)
	unlock_door(0x89, 0x40)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	remove_hudmsgs
	mute_channel(CHANNEL_5)
	mute_channel(CHANNEL_6)
	mute_channel(CHANNEL_7)
	dprint 'a','b','o','r','t','e','d',0,
	disable_object(0x2f)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func101a_move_jo_to_training_room[] = {
	// Wait for flag to be set while not in training
	beginloop(0x04)
		if_stage_flag_eq(STAGEFLAG_CONSIDER_WARP, TRUE, /*goto*/ 0x2f)
		reloop(0x04)

		label(0x2f)
#if VERSION >= VERSION_NTSC_1_0
		if_stage_flag_eq(STAGEFLAG_TRIGGER_UPLINK, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_ECMMINE, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CAMSPY, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_NIGHTVISION, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_DOORDECODER, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_RTRACKER, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_IR, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_XRAY, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_DISGUISE, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, TRUE, /*goto*/ 0x2f)
		goto_next(0x06)

		label(0x2f)
		reloop(0x04)

		label(0x06)
#endif
		unset_stage_flag(STAGEFLAG_CONSIDER_WARP)
		if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x2f)
		goto_next(0x30)

		// In room
		label(0x2f)
	endloop(0x04)

	// Not in room
	label(0x30)
	revoke_control(CHR_BOND, 0)
	fade_to_color(0x000000ff, 0)
	fade_to_color(0x00000000, 5000)
	restart_timer

	beginloop(0x08)
		if_timer_gt(30, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	if_chr_in_room(CHR_BOND, 0x00, 0x0016, /*goto*/ 0x2f)
	if_chr_in_room(CHR_BOND, 0x00, 0x0017, /*goto*/ 0x2f)
	if_chr_in_room(CHR_BOND, 0x00, 0x0018, /*goto*/ 0x2f)
	if_chr_in_room(CHR_BOND, 0x00, 0x0019, /*goto*/ 0x2f)
	if_chr_in_room(CHR_BOND, 0x00, 0x0014, /*goto*/ 0x2f)
	enter_camera_and_move_to_pad(PAD_DISH_0151)
	set_ailist(CHR_P1P2, AILIST_MOVE_TO_DEVICEROOM)
	goto_next(0x06)

	label(0x2f)
	enter_camera_and_move_to_pad(PAD_DISH_020A)
	set_ailist(CHR_P1P2, AILIST_MOVE_TO_HOLOROOM)

	label(0x06)
	yield
	yield
	yield
	yield
	enter_firstperson
	fade_to_color(0x000000ff, 0)
	fade_to_color(0x00000000, 90)
	restart_timer

	beginloop(0x09)
		if_timer_gt(90, /*goto*/ 0x06)
	endloop(0x09)

	label(0x06)
	grant_control(CHR_BOND)
	enter_firstperson
	unset_stage_flag(STAGEFLAG_CONSIDER_WARP)
	goto_first(0x04)

	endlist
};

u8 func0401_move_to_deviceroom[] = {
	chr_move_to_pad(CHR_SELF, PAD_DEVICEROOM, TRUE, /*goto*/ 0x06)
	label(0x06)
	stop_chr
	yield
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func0402_move_to_holoroom[] = {
	chr_move_to_pad(CHR_SELF, PAD_HOLOROOM, TRUE, /*goto*/ 0x06)
	label(0x06)
	stop_chr
	yield
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func0429_grimshaw_disguise[] = {
	set_returnlist(CHR_SELF, AILIST_GRIMSHAW_DISGUISE)
	dprint 'I','n','i','t','i','a','l','i','s','e','a',0,
	restart_timer

	beginloop(0x0f)
		if_timer_gt(60, /*goto*/ 0x8f)
	endloop(0x0f)

	beginloop(0x8f)
		if_stage_flag_eq(STAGEFLAG_CONSIDER_WARP, FALSE, /*goto*/ 0x04)
	endloop(0x8f)

	// Wait until Jo in sight
	beginloop(0x04)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x0d)
		if_can_see_target(/*goto*/ 0x2f)
		if_chr_idle(/*goto*/ 0x06)
		label(0x7f)
		call_rng
		if_rand_gt(1, /*goto*/ 0x06)
		set_ailist(CHR_SELF, GAILIST_DO_BORED_ANIMATION)
		label(0x06)
	endloop(0x04)

	label(0x2f)
	dprint 'I','n','i','t','i','a','l','i','s','e','b',0,
	restart_timer
	label(0x08)
	if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, TRUE, BANK_1, /*goto*/ 0x06)
	try_face_entity(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x09)

	beginloop(0x09)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x0d)
		if_target_in_fov_left(10, /*goto*/ 0x06)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x09)

	label(0x06)
	dprint 'I','n','i','t','i','a','l','i','s','e','c',0,
	do_preset_animation(PRESETANIM_TALK3)
	play_cistaff_quip(CIQUIP_GREETING, CHANNEL_6)
	restart_timer

	beginloop(0x57)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x0d)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x57)

	label(0x06)
	dprint 'I','n','i','t','i','a','l','i','s','e','d',0,
	restart_timer

	beginloop(0x58)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x0d)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x58)

	label(0x06)
	speak(CHR_BOND, L_DISH_043, MP3_0517, CHANNEL_6, COLOR_09_BLUE) // "I'm here to pick up the equipment."

	beginloop(0x59)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x0d)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x59)

	label(0x06)
	restart_timer

	beginloop(0x5b)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x0d)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x5b)

	label(0x06)
	if_chr_has_hiddenflag(CHR_BOND, CHRHFLAG_DISGUISED, /*goto*/ 0x2f)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_TARGET, L_DISH_044, MP3_0518, CHANNEL_6, COLOR_05_GREEN) // "Go away, Joanna. You're not fooling anybody!"

	beginloop(0x5c)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x0d)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x5c)

	label(0x06)
	set_stage_flag(STAGEFLAG_DISGUISE_FAILED)
	goto_next(0x0d)

	label(0x2f)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_TARGET, L_DISH_045, MP3_0519, CHANNEL_6, COLOR_05_GREEN) // "Here you go. Don't drop it now."

	beginloop(0x5d)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x0d)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x5d)

	label(0x06)
	give_object_to_chr(0x3c, CHR_BOND)
	set_stage_flag(STAGEFLAG_DISGUISE_COMPLETE)
	label(0x0d)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func100c_cloak_detection[] = {
	beginloop(0x04)
		deactivate_alarm
		dprint 'I','N','I','T','Y',0,
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, TRUE, /*goto*/ 0x8f)
		reloop(0x04)

		beginloop(0x8f)
			dprint 'L','O','O','P','Y',0,
			if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x5d)
			if_chr_distance_to_pad_lt(CHR_BOND, 200, PAD_DISH_027B, /*goto*/ 0x06)
		endloop(0x8f)

		beginloop(0x5d)
			dprint 'W','A','I','T','Y',0,
			if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, FALSE, /*goto*/ 0x30)
		endloop(0x5d)

		label(0x30)
		yield
		yield
		yield
		yield
		yield
		yield
		yield
		yield
		yield
		yield
	endloop(0x04)

	label(0x06)
	dprint 'G','O','T','T','H','R','U',0,
	if_chr_has_hiddenflag(CHR_BOND, CHRHFLAG_CLOAKED, /*goto*/ 0x30)
	activate_alarm
	yield
	restart_timer

	beginloop(0x09)
		if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x59)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x09)

	label(0x06)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	speak(CHR_TARGET, L_DISH_048, MP3_051A, CHANNEL_6, COLOR_05_GREEN) // "You'll have to do better than that, Joanna."
	show_hudmsg(CHR_BOND, L_DISH_050) // "You have been detected by the camera."
	restart_timer

	beginloop(0x0a)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, FALSE, /*goto*/ 0x30)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x0a)

	label(0x06)
	set_stage_flag(STAGEFLAG_CLOAK_FAILED)
	restart_timer

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, FALSE, /*goto*/ 0x30)
		if_timer_gt(120, /*goto*/ 0x59)
	endloop(0x08)

	label(0x59)
	deactivate_alarm

	beginloop(0x5a)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, FALSE, /*goto*/ 0x30)
	endloop(0x5a)

	label(0x30)
	deactivate_alarm
	restart_timer

	beginloop(0x5c)
		yield
		dprint 'W','A','I','T','F','I','N',0,
		if_timer_gt(60, /*goto*/ 0x2f)
	endloop(0x5c)

	label(0x2f)
	goto_first(0x04)

	label(0x06)
	goto_first(0x8f)

	endlist
};

u8 func042a_carrington_cloak[] = {
	set_returnlist(CHR_SELF, AILIST_CARRINGTON_CLOAK)

	beginloop(0x8f)
		chr_move_to_pad(CHR_SELF, PAD_CARRINGTON_OFFICE, TRUE, /*goto*/ 0x06)
	endloop(0x8f)

	label(0x06)
	dprint 'I','n','i','t','i','a','l','i','s','e','a',0,

	beginloop(0x04)
		if_can_see_target(/*goto*/ 0x2f)
		if_chr_idle(/*goto*/ 0x06)
		label(0x7f)
		call_rng
		if_rand_gt(1, /*goto*/ 0x06)
		set_ailist(CHR_SELF, GAILIST_DO_BORED_ANIMATION)

		label(0x06)
	endloop(0x04)

	label(0x2f)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	close_door(0x40)
	dprint 'I','n','i','t','i','a','l','i','s','e','b',0,
	restart_timer
	label(0x08)
	if_self_flag_bankx_eq(CHRFLAG1_DOINGIDLEANIMATION, TRUE, BANK_1, /*goto*/ 0x06)
	try_face_entity(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x09)

	beginloop(0x09)
		if_target_in_fov_left(10, /*goto*/ 0x06)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x09)

	label(0x06)
	dprint 'I','n','i','t','i','a','l','i','s','e','c',0,
	restart_timer
	chr_do_animation(ANIM_WALK_BACKWARDS, -1, -1, CHRANIMFLAG_SLOWUPDATE, 16, CHR_SELF, 2)
	restart_timer

	beginloop(0x57)
		if_timer_gt(30, /*goto*/ 0x06)
	endloop(0x57)

	label(0x06)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_BOND, L_DISH_049, MP3_051B, CHANNEL_6, COLOR_06_WHITE) // "Joanna, where did you spring from?"

	beginloop(0x59)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x59)

	label(0x06)
	restart_timer

	beginloop(0x5b)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x5b)

	label(0x06)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_TARGET, L_DISH_053, MP3_051C, CHANNEL_6, COLOR_06_WHITE) // "I think we can safely say your training is now complete!"

	beginloop(0x5c)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x5c)

	label(0x06)
	stop_chr
	set_stage_flag(STAGEFLAG_CLOAK_COMPLETE)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func100e_training_unlockables[] = {
	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_UPLINK_DONE, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	unlock_door(0x3e, 0x40)

	beginloop(0x08)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_ECMMINE_DONE, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	unlock_door(0x3d, 0x40)
	unlock_door(0x3f, 0x40)
	goto_next(0x2f)

	beginloop(0x09)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_CAMSPY_DONE, /*goto*/ 0x2f)
	endloop(0x09)

	label(0x2f)
	unset_object_flag2(OBJ_LIGHTSWITCH, OBJFLAG2_INVISIBLE)

	beginloop(0x0a)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_NIGHTVISION_DONE, /*goto*/ 0x2f)
	endloop(0x0a)

	label(0x2f)
	set_lights_state(0x0030, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x002e, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x002f, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0020, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0024, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0025, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0026, LIGHTOP_SET, 255, 0, 0)
	set_lights_state(0x0022, LIGHTOP_SET, 255, 0, 0)

	beginloop(0x0b)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_DOORDECODER_DONE, /*goto*/ 0x2f)
	endloop(0x0b)

	label(0x2f)
	unlock_door(0x41, 0x40)

	beginloop(0x0e)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_IR_DONE, /*goto*/ 0x2f)
	endloop(0x0e)

	label(0x2f)
	unlock_door(0x37, 0x40)

	beginloop(0x0f)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_XRAY_DONE, /*goto*/ 0x2f)
	endloop(0x0f)

	label(0x2f)
	disable_object(0x3a)
	disable_object(0x3b)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

#define do_door_proxy(eepromflag, pad, door) \
	/* If training flag is done, open/close a door automatically as Jo nears it */ \
	beginloop(0x04) \
		if_savefile_flag_is_set(eepromflag, /*goto*/ 0x2f) \
		reloop(0x04) \
 \
		label(0x2f) \
		if_chr_distance_to_pad_lt(CHR_BOND, 350, pad, /*goto*/ 0x06) \
		close_door(door) \
		reloop(0x04) \
 \
		label(0x06) \
		if_door_state(door, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x2f) \
		open_door(door) \
		set_object_flag(door, OBJFLAG_DOOR_KEEPOPEN) \
		restart_timer \
 \
		beginloop(0x08) \
			if_timer_gt(120, /*goto*/ 0x2f) \
		endloop(0x08) \
 \
		label(0x2f) \
	endloop(0x04)

u8 func100f_doorproxy_unused1[] = {
	set_ailist(CHR_SELF, GAILIST_IDLE)

	// Unreachable
	do_door_proxy(GAMEFILEFLAG_CI_ECMMINE_DONE, 0x0185, 0x3d)
	endlist
};

u8 func1010_doorproxy[] = {
	do_door_proxy(GAMEFILEFLAG_CI_UPLINK_DONE, 0x0186, 0x3e)
	endlist
};

u8 func1010_doorproxy_unused2[] = {
	set_ailist(CHR_SELF, GAILIST_IDLE)

	// Unreachable
	do_door_proxy(GAMEFILEFLAG_CI_ECMMINE_DONE, 0x0187, 0x3f)
	endlist
};

u8 func1012_cloak_doorproxy[] = {
	beginloop(0x04)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, TRUE, /*goto*/ 0x2f)
		reloop(0x04)

		label(0x2f)
		if_stage_flag_eq(STAGEFLAG_CLOAK_FAILED, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_DEVICE_ABORTING, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_DEVICE_SUCCESS, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_DEVICE_FAILURE, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 350, PAD_DISH_0188, /*goto*/ 0x06)
		close_door(0x40)
		label(0x2f)
	endloop(0x04)

	label(0x06)
	if_door_state(0x40, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x2f)
	open_door(0x40)
	set_object_flag(0x40, OBJFLAG_DOOR_KEEPOPEN)
	restart_timer

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	goto_first(0x04)

	endlist
};

#if VERSION >= VERSION_NTSC_1_0
u8 func101b_ir_door[] = {
	beginloop(0x04)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_IR, TRUE, /*goto*/ 0x06)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_IR_DONE, /*goto*/ 0x2f)
		label(0x06)
		reloop(0x04)

		label(0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 350, PAD_DISH_0192, /*goto*/ 0x06)
		close_door(0x37)
	endloop(0x04)

	label(0x06)
	if_door_state(0x37, (DOORSTATE_OPEN | DOORSTATE_OPENING), /*goto*/ 0x2f)
	open_door(0x37)
	set_object_flag(0x37, OBJFLAG_DOOR_KEEPOPEN)
	restart_timer

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	goto_first(0x04)

	endlist
};
#endif

u8 func042b_init_carrington[] = {
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_UNEXPLODABLE)
	yield
	set_morale(0)
	if_savefile_flag_is_unset(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x06)
#if VERSION >= VERSION_NTSC_1_0
	set_savefile_flag(GAMEFILEFLAG_CI_TOUR_DONE)
#endif
	dprint 'E','E','P','R','O','M',' ','S','E','T',0,

	beginloop(0x08)
		chr_move_to_pad(CHR_SELF, PAD_CARRINGTON_OFFICE, TRUE, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	set_ailist(CHR_SELF, 0x041e)

	label(0x06)
	dprint 'E','E','P','R','O','M',' ','N','O','T','S','E','T',0,
	if_savefile_flag_is_unset(GAMEFILEFLAG_CI_TOUR_DONE, /*goto*/ 0x8f)
	goto_first(0x08)

	beginloop(0x8f)
		chr_move_to_pad(CHR_SELF, PAD_OUTSIDE_JO_OFFICE, TRUE, /*goto*/ 0x2f)
	endloop(0x8f)

	label(0x2f)
	stop_chr
	set_ailist(CHR_SELF, AILIST_CARRINGTON_TOUR)
	endlist
};

u8 func1019_setup_carrington[] = {
	beginloop(0x04)
		if_chr_has_hiddenflag(CHR_CARRINGTON, CHRHFLAG_INFINITESHIELD, /*goto*/ 0x06)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x06)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	label(0x2f)
	set_ailist(CHR_CARRINGTON, AILIST_INIT_CARRINGTON)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func042c_carrington_tour[] = {
	set_returnlist(CHR_SELF, AILIST_CARRINGTON_TOUR)
	set_self_chrflag(CHRCFLAG_NEVERSLEEP)
	restart_timer
	try_face_entity(ATTACKFLAG_AIMATPAD, 0x0054, /*goto*/ 0x04)

	beginloop(0x04)
		dprint 'F','A','C','E',' ','P','A','D',0,
		if_timer_gt(1200, /*goto*/ 0x2f)
		if_los_to_target(/*goto*/ 0x2f)
		if_chr_idle(/*goto*/ 0x06)
		label(0x7f)
		call_rng
		if_rand_gt(1, /*goto*/ 0x06)
		set_ailist(CHR_SELF, GAILIST_DO_BORED_ANIMATION)

		label(0x06)
	endloop(0x04)

	label(0x2f)
	if_los_to_target(/*goto*/ 0x06)
	try_jog_to_target(/*goto*/ 0x08)

	beginloop(0x08)
		if_los_to_target(/*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	set_chr_hiddenflag(CHR_SELF, CHRHFLAG_INFINITESHIELD)
	set_savefile_flag(GAMEFILEFLAG_CI_TOUR_STARTED)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	remove_hudmsgs
	speak(CHR_TARGET, L_DISH_066, SFX_8029, CHANNEL_6, COLOR_06_WHITE) // "Joanna, it's good to see you."
	restart_timer

	beginloop(0x57)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x57)

	label(0x06)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_TARGET, L_DISH_067, MP3_051D, CHANNEL_6, COLOR_06_WHITE) // "Come with me. I'll walk you round the training rooms."
	restart_timer

	beginloop(0x59)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x59)

	label(0x06)
	walk_to_pad(PAD_DISH_0064)

	beginloop(0x5b)
		if_chr_stopped(/*goto*/ 0x06)
	endloop(0x5b)

	label(0x06)
	stop_chr
	restart_timer
	try_face_entity(ATTACKFLAG_AIMATPAD, 0x0068, /*goto*/ 0x5c)

	beginloop(0x5c)
		if_timer_lt(60, /*goto*/ 0x06)
		if_los_to_target(/*goto*/ 0x2f)
		label(0x06)
	endloop(0x5c)

	label(0x2f)
	if_distance_to_target_lt(500, /*goto*/ 0x2f)
	goto_first(0x5c)

	label(0x2f)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	remove_hudmsgs
	speak(CHR_TARGET, L_DISH_068, MP3_0520, CHANNEL_6, COLOR_06_WHITE) // "The information center is through this door."
	restart_timer

	beginloop(0x5d)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x5d)

#if VERSION < VERSION_NTSC_1_0
	label(0x06)
	walk_to_pad(PAD_DISH_0068)

	beginloop(0x5e)
		if_chr_stopped(/*goto */ 0x06)
	endloop(0x5e)

	label(0x06)
	restart_timer
	try_face_entity(ATTACKFLAG_AIMATCHR, 0x03, /*goto*/ 0x5f)

	beginloop(0x5f)
		if_timer_gt(40, /*goto*/ 0x06)
	endloop(0x5f)

	label(0x06)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	play_sound(SFX_802A, CHANNEL_6)
	set_ailist(0x03, 0x042d)
	restart_timer

	beginloop(0x60)
		if_timer_gt(40, /*goto*/ 0x06)
	endloop(0x60)

	label(0x06)
	mute_channel(CHANNEL_6)
	stop_chr
	yield
	yield

	beginloop(0x61)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x61)
#endif

	label(0x06)
	walk_to_pad(PAD_DISH_0065)

	beginloop(0x62)
		if_chr_stopped(/*goto*/ 0x06)
	endloop(0x62)

	label(0x06)
	stop_chr

	beginloop(0x63)
		if_los_to_target(/*goto*/ 0x2f)
	endloop(0x63)

	label(0x2f)
	if_distance_to_target_lt(500, /*goto*/ 0x2f)
	goto_first(0x63)

	label(0x2f)
#if VERSION >= VERSION_NTSC_1_0
	set_ailist(0x01, GAILIST_IDLE)
#endif
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_TARGET, L_DISH_069, MP3_051F, CHANNEL_6, COLOR_06_WHITE) // "In here we have the device lab."
	restart_timer

	beginloop(0x64)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x64)

	label(0x06)
	restart_timer
	try_face_entity(ATTACKFLAG_AIMATCHR, 0x01, /*goto*/ 0x65)

	beginloop(0x65)
		if_timer_gt(40, /*goto*/ 0x06)
	endloop(0x65)

	label(0x06)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	play_sound(SFX_CARR_HELLO_JOANNA, CHANNEL_6)
	set_ailist(0x01, AILIST_DEVICEGIRL_REPLY_TO_CARRINGTON)
	restart_timer

	beginloop(0x66)
		if_timer_gt(20, /*goto*/ 0x06)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x66)

	label(0x06)
	mute_channel(CHANNEL_6)
	stop_chr
	yield
	yield

	beginloop(0x68)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x68)

	label(0x06)
	walk_to_pad(PAD_DISH_0020)

	beginloop(0x69)
		if_chr_stopped(/*goto*/ 0x06)
	endloop(0x69)

	label(0x06)
	stop_chr

	beginloop(0x6a)
		if_los_to_target(/*goto*/ 0x2f)
	endloop(0x6a)

	label(0x2f)
	if_distance_to_target_lt(500, /*goto*/ 0x2f)
	goto_first(0x6a)

	label(0x2f)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_TARGET, L_DISH_070, MP3_0521, CHANNEL_6, COLOR_06_WHITE) // "This leads to the simulant training room."
	restart_timer

	beginloop(0x6b)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x6b)

	label(0x06)
	stop_chr
	yield
	yield

	beginloop(0x6c)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x6c)

	label(0x06)
	walk_to_pad(PAD_DISH_0010)

	beginloop(0x6d)
		if_chr_stopped(/*goto*/ 0x06)
	endloop(0x6d)

	label(0x06)
	stop_chr

	beginloop(0x6e)
		if_los_to_target(/*goto*/ 0x2f)
	endloop(0x6e)

	label(0x2f)
	if_distance_to_target_lt(500, /*goto*/ 0x2f)
	goto_first(0x6e)

	label(0x2f)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_TARGET, L_DISH_071, MP3_051E, CHANNEL_6, COLOR_06_WHITE) // "This is the firing range, Jo."
	restart_timer

	beginloop(0x6f)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x6f)

	label(0x06)
	restart_timer
	try_face_entity(ATTACKFLAG_AIMATCHR, 0x01, /*goto*/ 0x70)

	beginloop(0x70)
		if_timer_gt(40, /*goto*/ 0x06)
	endloop(0x70)

	label(0x06)
#if VERSION < VERSION_NTSC_1_0
	set_ailist(0x01, 0x042e)
#endif
	restart_timer

	beginloop(0x71)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x71)

	label(0x06)
	stop_chr
	yield
	yield

	beginloop(0x72)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x72)

	label(0x06)
	label(0x06)
	walk_to_pad(PAD_DISH_0009)

	beginloop(0x73)
		if_chr_stopped(/*goto*/ 0x06)
	endloop(0x73)

	label(0x06)
	stop_chr

	beginloop(0x74)
		if_los_to_target(/*goto*/ 0x2f)
	endloop(0x74)

	label(0x2f)
	if_distance_to_target_lt(500, /*goto*/ 0x2f)
	goto_first(0x74)

	label(0x2f)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_TARGET, L_DISH_072, MP3_0522, CHANNEL_6, COLOR_06_WHITE) // "This corridor leads down to the hangar."
	restart_timer

	beginloop(0x75)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x75)

	label(0x06)
	restart_timer
	set_target_chr(CHR_BOND)
	try_face_entity(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x79)

	beginloop(0x79)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x79)

	label(0x2f)
	do_preset_animation(PRESETANIM_TALKRANDOM)
	speak(CHR_TARGET, L_DISH_124, MP3_07DC, CHANNEL_6, COLOR_06_WHITE) // "Okay, Jo, I'll leave you to prepare for the mission."

	beginloop(0x7a)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x2f)
	endloop(0x7a)

	label(0x2f)
	set_savefile_flag(GAMEFILEFLAG_CI_TOUR_DONE)
	walk_to_pad(PAD_CARRINGTON_OFFICE)

	beginloop(0x76)
		if_chr_stopped(/*goto*/ 0x06)
	endloop(0x76)

	label(0x06)
	set_ailist(CHR_SELF, 0x041e)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func042d_unused[] = {
	set_alertness(1)
	set_self_chrflag(CHRCFLAG_NEVERSLEEP)
	restart_timer
	try_face_entity(ATTACKFLAG_AIMATCHR, CHR_CARRINGTON, /*goto*/ 0x5f)

	beginloop(0x5f)
		if_timer_gt(40, /*goto*/ 0x06)
	endloop(0x5f)

	label(0x06)

	beginloop(0x60)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x60)

	label(0x06)
	assign_sound(SFX_GRIMSHAW_HI_THERE, CHANNEL_6)
	play_sound_from_entity(CHANNEL_6, CHR_SELF, 0x0bb8, 0x1770, 0x01)

	beginloop(0x61)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x61)

	label(0x06)
	set_ailist(CHR_SELF, 0x041e)
	endlist
};

u8 func042e_devicegirl_reply_to_carrington[] = {
	set_alertness(1)
	set_self_chrflag(CHRCFLAG_NEVERSLEEP)
	restart_timer
	try_face_entity(ATTACKFLAG_AIMATCHR, CHR_CARRINGTON, /*goto*/ 0x5f)

	beginloop(0x5f)
		if_timer_gt(40, /*goto*/ 0x06)
	endloop(0x5f)

	label(0x06)

	beginloop(0x60)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x60)

	label(0x06)
	yield
	yield
	yield
	assign_sound(MP3_CIFEM_PATIENCE, CHANNEL_6)
	play_sound_from_entity(CHANNEL_6, CHR_SELF, 0x0bb8, 0x1770, 0x01)

	beginloop(0x61)
		if_sound_finished(CHANNEL_6, /*goto*/ 0x06)
	endloop(0x61)

	label(0x06)
	set_ailist(CHR_SELF, 0x041e)
	endlist
};

u8 func1013_msg_hovercrate[] = {
#if VERSION >= VERSION_PAL_BETA
	beginloop(0x8f)
		if_savefile_flag_is_unset(GAMEFILEFLAG_HOWTO_HOVERCRATE, /*goto*/ 0x04)
	endloop(0x8f)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_HOWTO_HOVERCRATE, /*goto*/ 0x06)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0141, /*goto*/ 0x2f)
	endloop(0x04)
#else
	if_savefile_flag_is_unset(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x04)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x06)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0141, /*goto*/ 0x2f)
	endloop(0x04)
#endif

	label(0x06)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	label(0x2f)
#if VERSION >= VERSION_PAL_BETA
	set_savefile_flag(GAMEFILEFLAG_HOWTO_HOVERCRATE)
#endif
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_073) // "HOVERCRATE Press B Button next to Hovcrate to grab it..."
	restart_timer

	beginloop(0x08)
		if_timer_gt(240, /*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_074) // "Press B Button when crate grabbed to release it."
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1014_msg_hoverbike[] = {
#if VERSION >= VERSION_PAL_BETA
	beginloop(0x8f)
		if_savefile_flag_is_unset(GAMEFILEFLAG_HOWTO_HOVERBIKE, /*goto*/ 0x04)
	endloop(0x8f)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_HOWTO_HOVERBIKE, /*goto*/ 0x06)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_01F9, /*goto*/ 0x2f)
	endloop(0x04)
#else
	if_savefile_flag_is_unset(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x04)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x06)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_01F9, /*goto*/ 0x2f)
	endloop(0x04)
#endif

	label(0x06)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	label(0x2f)
#if VERSION >= VERSION_PAL_BETA
	set_savefile_flag(GAMEFILEFLAG_HOWTO_HOVERBIKE)
#endif
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_075) // "HOVERBIKE Double tap B Button next to Hovbike to ride it..."
	restart_timer

	beginloop(0x08)
		if_timer_gt(240, /*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_076) // "Double tap B Button when on Hovbike to dismount."
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1015_msg_doors[] = {
#if VERSION >= VERSION_PAL_BETA
	beginloop(0x8f)
		if_savefile_flag_is_unset(GAMEFILEFLAG_HOWTO_DOORS, /*goto*/ 0x04)
	endloop(0x8f)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_HOWTO_DOORS, /*goto*/ 0x06)
	endloop(0x04)
#else
	if_savefile_flag_is_unset(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x04)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x06)
	endloop(0x04)
#endif

	label(0x06)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	label(0x2f)
#if VERSION >= VERSION_PAL_BETA
	set_savefile_flag(GAMEFILEFLAG_HOWTO_DOORS)
#endif
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_077) // "OPENING DOORS Press B Button next to door to open it."
	restart_timer

	beginloop(0x08)
		if_timer_gt(240, /*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_078) // "B Button will also activate any object nearby."
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1016_msg_elevators[] = {
#if VERSION >= VERSION_PAL_BETA
	beginloop(0x8f)
		if_savefile_flag_is_unset(GAMEFILEFLAG_HOWTO_ELEVATORS, /*goto*/ 0x04)
	endloop(0x8f)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_HOWTO_ELEVATORS, /*goto*/ 0x06)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0160, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0162, /*goto*/ 0x2f)
	endloop(0x04)
#else
	if_savefile_flag_is_unset(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x04)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x06)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0160, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0162, /*goto*/ 0x2f)
	endloop(0x04)
#endif

	label(0x2f)
#if VERSION >= VERSION_PAL_BETA
	set_savefile_flag(GAMEFILEFLAG_HOWTO_ELEVATORS)
#endif
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_079) // "ELEVATORS Press B Button next to door to call elevator."
	label(0x06)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1017_msg_terminals[] = {
#if VERSION >= VERSION_PAL_BETA
	beginloop(0x8f)
		if_savefile_flag_is_unset(GAMEFILEFLAG_HOWTO_TERMINALS, /*goto*/ 0x04)
	endloop(0x8f)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_HOWTO_TERMINALS, /*goto*/ 0x06)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0227, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_022A, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_021C, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_021E, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0221, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0224, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_023E, /*goto*/ 0x2f)
	endloop(0x04)
#else
	if_savefile_flag_is_unset(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x04)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	beginloop(0x04)
		if_savefile_flag_is_set(GAMEFILEFLAG_CI_TOUR_STARTED, /*goto*/ 0x06)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0227, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_022A, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_021C, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_021E, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0221, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_0224, /*goto*/ 0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 250, PAD_DISH_023E, /*goto*/ 0x2f)
	endloop(0x04)
#endif

	label(0x2f)
#if VERSION >= VERSION_PAL_BETA
	set_savefile_flag(GAMEFILEFLAG_HOWTO_TERMINALS)
#endif
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_114) // "TERMINALS - Press B Button next to terminal to use it."
	label(0x06)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1018_lightswitch[] = {
	beginloop(0x04)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_NIGHTVISION, FALSE, /*goto*/ 0x2f)
		if_player_using_device(CHR_BOND, WEAPON_NIGHTVISION, /*goto*/ 0x2f)
		set_object_flag2(OBJ_LIGHTSWITCH, OBJFLAG2_INVISIBLE)
		reloop(0x04)

		label(0x2f)
		unset_object_flag2(OBJ_LIGHTSWITCH, OBJFLAG2_INVISIBLE)
	endloop(0x04)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func101c_holo1_main[] = {
	label(0x80)
	disable_object(0x48)
	disable_object(0x49)
	disable_object(0x4a)
	disable_object(0x4b)
	disable_object(0x4c)
	disable_object(0x4d)
	disable_object(0x4e)
	disable_object(0x4f)

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO1, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
	restart_timer

	beginloop(0x13)
		if_timer_gt(30, /*goto*/ 0x2f)
	endloop(0x13)

	label(0x2f)
	lock_door(0x75, 0x40)
	lock_door(0x76, 0x40)
	close_door(0x75)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x2f)
	if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x2f)
	label(0x2f)
	unset_stage_flag(STAGEFLAG_HOLO_ABORTING)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	unset_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	disable_object(0x45)
	enable_object(0x48)
	enable_object(0x49)
	enable_object(0x4a)
	enable_object(0x4b)
	enable_object(0x4c)
	enable_object(0x4d)
	enable_object(0x4e)
	enable_object(0x4f)
	unset_object_flag2(0x48, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x49, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x4a, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x4b, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x4c, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x4d, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x4e, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x4f, OBJFLAG2_IMMUNETOANTI)
	disable_chr(0x04)
	dprint 't','r','a','i','n','i','n','g',0,
	label(0x91)
	if_object_flag2(0x4c, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	if_object_flag2(0x4d, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	if_object_flag2(0x4e, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	if_object_flag2(0x4f, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	label(0x06)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_100) // "Get the access codes by examining terminals. - Use the codes on the wall terminals."
	goto_next(0x06)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_115) // "Now activate the red terminals on the wall."
	label(0x06)
	restart_timer

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x90)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_SUCCESS, TRUE, /*goto*/ 0x83)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_FAILURE, TRUE, /*goto*/ 0x85)
		if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(1200, /*goto*/ 0x2f)
	endloop(0x82)

	label(0x2f)
	goto_first(0x91)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_HOLO1_DONE)
	dprint 'd','o','n','e',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	yield
	goto_next(0x84)

	label(0x84)
	if_chr_in_room(CHR_BOND, 0x00, 0x001e, /*goto*/ 0x90)
	label(0x90)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	unlock_door(0x75, 0x40)
	unlock_door(0x76, 0x40)
	remove_hudmsgs
	mute_channel(CHANNEL_5)
	mute_channel(CHANNEL_6)
	mute_channel(CHANNEL_7)
	enable_chr(0x04)
	dprint 'a','b','o','r','t','e','d',0,
	disable_object(0x48)
	disable_object(0x49)
	disable_object(0x4a)
	disable_object(0x4b)
	disable_object(0x4c)
	disable_object(0x4d)
	disable_object(0x4e)
	disable_object(0x4f)
	enable_object(0x45)
	remove_hudmsgs
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

#define holo1_some_terminal(object, function) \
	beginloop(0x8f) \
		if_stage_flag_eq(STAGEFLAG_IN_HOLO1, TRUE, /*goto*/ 0x2f) \
	endloop(0x8f) \
 \
	label(0x2f) \
	set_object_image(object, 0, TVCMDLIST_12) \
	unset_object_flag2(object, OBJFLAG2_INVHIDDEN) \
 \
	beginloop(0x04) \
		if_chr_activated_object(CHR_ANY, object, /*goto*/ 0x2f) \
		reloop(0x04) \
 \
		label(0x2f) \
		if_object_flag2(object, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f) \
	endloop(0x04) \
 \
	label(0x2f) \
	set_object_image(object, 0, TVCMDLIST_13) \
	set_object_flag2(object, OBJFLAG2_INVHIDDEN) \
	assign_sound(SFX_043A, CHANNEL_7) \
	set_object_sound_playing(CHANNEL_7, object, TRUE) \
	set_returnlist(CHR_SELF, function) \
	set_ailist(CHR_SELF, AILIST_HOLO1_CHECK_DONE)

u8 func101d_holo1_switch1[] = {
	holo1_some_terminal(0x4c, AILIST_HOLO1_SWITCH1)
	endlist
};

u8 func101e_holo1_switch2[] = {
	holo1_some_terminal(0x4d, AILIST_HOLO1_SWITCH2)
	endlist
};

u8 func101f_holo1_switch3[] = {
	holo1_some_terminal(0x4e, AILIST_HOLO1_SWITCH3)
	endlist
};

u8 func1020_holo1_monitor_switches[] = {
	beginloop(0x8f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO1, TRUE, /*goto*/ 0x2f)
	endloop(0x8f)

	label(0x2f)
	set_object_image(0x4f, 0, TVCMDLIST_12)
	unset_object_flag2(0x4f, OBJFLAG2_INVHIDDEN)

	beginloop(0x04)
		if_chr_activated_object(CHR_ANY, 0x4f, /*goto*/ 0x2f)
		reloop(0x04)

		label(0x2f)
		if_object_flag2(0x4f, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	set_object_image(0x4f, 0, TVCMDLIST_13)
	set_object_flag2(0x4f, OBJFLAG2_INVHIDDEN)
	assign_sound(SFX_043A, CHANNEL_7)
	set_object_sound_playing(CHANNEL_7, 0x4f, TRUE)
	set_returnlist(CHR_SELF, AILIST_HOLO1_MONITOR_SWITCHES)
	set_ailist(CHR_SELF, AILIST_HOLO1_CHECK_DONE)
	endlist
};

#define holo1_code_thing_p1(object1, object2, pad) \
	yield \
	yield \
	yield \
 \
	beginloop(0x04) \
		if_stage_flag_eq(STAGEFLAG_IN_HOLO1, TRUE, /*goto*/ 0x2f) \
		reloop(0x04) \
 \
		label(0x2f) \
		if_object_in_good_condition(object1, /*goto*/ 0x2f) \
		reloop(0x04) \
 \
		label(0x2f) \
		if_object_flag2(object1, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f) \
		if_chr_distance_to_pad_lt(CHR_BOND, 400, pad, /*goto*/ 0x09) \
		label(0x2f) \
		if_chr_looking_at_object(CHR_BOND, object1, /*goto*/ 0x2f) \
	endloop(0x04) \
 \
	label(0x09)

#define holo1_code_thing_p2(object1, object2, hint, msg) \
	remove_hudmsgs \
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, hint) \
	goto_first(0x04) \
 \
	label(0x2f) \
	set_object_image(object2, 0, TVCMDLIST_12) \
	set_object_image(object1, 0, TVCMDLIST_13) \
	remove_hudmsgs \
	show_hudmsg(CHR_BOND, msg) \
	assign_sound(SFX_DOOR_81B0, CHANNEL_7) \
	set_object_sound_playing(CHANNEL_7, object1, TRUE) \
	restart_timer \
 \
	beginloop(0x57) \
		if_timer_gt(60, /*goto*/ 0x2f) \
	goto_first(0x57) \
 \
	label(0x2f) \
	set_object_flag2(object2, OBJFLAG2_IMMUNETOANTI) \
 \
	beginloop(0x59) \
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_SUCCESS, TRUE, /*goto*/ 0x2f) \
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x2f) \
		reloop(0x59) \
 \
		label(0x2f) \
		if_stage_flag_eq(STAGEFLAG_IN_HOLO1, FALSE, /*goto*/ 0x2f) \
	endloop(0x59) \
 \
	label(0x2f) \
	goto_first(0x8f)

u8 func1021_holo1_code1[] = {
	label(0x8f)
	set_object_image(0x48, 0, TVCMDLIST_12)
	unset_object_flag2(0x4c, OBJFLAG2_IMMUNETOANTI)

	holo1_code_thing_p1(0x48, 0x4c, 0x0240)

	set_object_flag2(0x48, OBJFLAG2_IMMUNETOANTI)
	set_object_flag2(0x4c, OBJFLAG2_IMMUNETOANTI)

	// 0x1c55 = "LOOK UP - Press Down C Button to look up at the target."
	// 0x1c65 = "Code 1 has been obtained."
	holo1_code_thing_p2(0x48, 0x4c, 0x1c55, 0x1c65)

	endlist
};

u8 func1021_holo1_code2[] = {
	label(0x8f)
	set_object_image(0x49, 0, TVCMDLIST_12)
	unset_object_flag2(0x4d, OBJFLAG2_IMMUNETOANTI)

	holo1_code_thing_p1(0x49, 0x4d, 0x0241)

	set_object_flag2(0x49, OBJFLAG2_IMMUNETOANTI)

	// 0x1c56 = "LOOK DOWN - Press Up C Button to look down at the target."
	// 0x1c66 = "Code 2 has been obtained."
	holo1_code_thing_p2(0x49, 0x4d, 0x1c56, 0x1c66)
	endlist
};

u8 func1021_holo1_code3[] = {
	label(0x8f)
	unset_object_flag2(0x4e, OBJFLAG2_IMMUNETOANTI)
	set_object_image(0x4a, 0, TVCMDLIST_12)

	holo1_code_thing_p1(0x4a, 0x4e, 0x0242)

	set_object_flag2(0x4a, OBJFLAG2_IMMUNETOANTI)

	// 0x1c55 = "LOOK UP - Press Down C Button to look up at the target."
	// 0x1c67 = "Code 3 has been obtained."
	holo1_code_thing_p2(0x4a, 0x4e, 0x1c55, 0x1c67)
	endlist
};

u8 func1021_holo1_code4[] = {
	label(0x8f)
	unset_object_flag2(0x4f, OBJFLAG2_IMMUNETOANTI)
	set_object_image(0x4b, 0, TVCMDLIST_12)

	holo1_code_thing_p1(0x4b, 0x4f, 0x0243)

	set_object_flag2(0x4b, OBJFLAG2_IMMUNETOANTI)

	// 0x1c55 = "LOOK UP - Press Down C Button to look up at the target."
	// 0x1c68 = "Code 4 has been obtained."
	holo1_code_thing_p2(0x4b, 0x4f, 0x1c55, 0x1c68)
	endlist
};

u8 func0430_holo1_check_done[] = {
	label(0x04)
	yield
	if_object_flag2(0x4c, OBJFLAG2_INVHIDDEN, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	dprint 'D','O','H','1',0,
	if_object_flag2(0x4d, OBJFLAG2_INVHIDDEN, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	dprint 'D','O','H','2',0,
	if_object_flag2(0x4e, OBJFLAG2_INVHIDDEN, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	dprint 'D','O','H','3',0,
	if_object_flag2(0x4f, OBJFLAG2_INVHIDDEN, /*goto*/ 0x2f)
	goto_next(0x06)

	// All flags are set
	label(0x2f)
	dprint 'D','O','H','4',0,
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_106) // "Holoprogram 1 has been completed successfully."
	restart_timer

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)

	label(0x06)

	beginloop(0x57)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO1, FALSE, /*goto*/ 0x2f)
	endloop(0x57)

	label(0x2f)
	return

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1022_holo2_main[] = {
	label(0x80)
	disable_object(0x54)
	disable_object(0x55)
	disable_object(0x56)
	disable_object(0x57)

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO2, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
	restart_timer

	beginloop(0x13)
		if_timer_gt(30, /*goto*/ 0x2f)
	endloop(0x13)

	label(0x2f)
	lock_door(0x75, 0x40)
	lock_door(0x76, 0x40)
	close_door(0x75)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x2f)
	if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x2f)
	label(0x2f)
	unset_object_flag2(0x54, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x55, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x56, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x57, OBJFLAG2_IMMUNETOANTI)
	set_object_image(0x54, 0, TVCMDLIST_14)
	set_object_image(0x55, 0, TVCMDLIST_14)
	set_object_image(0x56, 0, TVCMDLIST_14)
	set_object_image(0x57, 0, TVCMDLIST_14)
	unset_stage_flag(STAGEFLAG_HOLO_ABORTING)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	unset_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	disable_object(0x45)
	enable_object(0x54)
	enable_object(0x55)
	enable_object(0x56)
	enable_object(0x57)
	disable_chr(0x04)
	dprint 't','r','a','i','n','i','n','g',0,
	label(0x2f)
	label(0x91)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_099) // "Activate all of the wall switches. - Be quick, as they will quickly reset."
	restart_timer

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x90)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_FAILURE, TRUE, /*goto*/ 0x85)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_SUCCESS, TRUE, /*goto*/ 0x83)
		if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x57)
		goto_next(0x59)
		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(1200, /*goto*/ 0x2f)
	endloop(0x82)

	label(0x2f)
	goto_first(0x91)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	goto_next(0x90)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_HOLO2_DONE)
	dprint 'd','o','n','e',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	yield
	goto_next(0x84)

	label(0x84)
	remove_hudmsgs
	label(0x90)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	unlock_door(0x75, 0x40)
	unlock_door(0x76, 0x40)
	mute_channel(CHANNEL_5)
	mute_channel(CHANNEL_6)
	mute_channel(CHANNEL_7)
	enable_chr(0x04)
	dprint 'a','b','o','r','t','e','d',0,
	disable_object(0x54)
	disable_object(0x55)
	disable_object(0x56)
	disable_object(0x57)
	enable_object(0x45)
	restart_timer

	beginloop(0x09)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x09)

	label(0x06)
	remove_hudmsgs
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

#define holo2_do_thing(object, function) \
	restart_timer \
	beginloop(0x04) \
		if_chr_activated_object(CHR_ANY, object, /*goto*/ 0x2f) \
		if_object_flag2(object, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x06) \
		reloop(0x04) \
 \
		label(0x06) \
		if_timer_gt(300, /*goto*/ 0x06) \
		reloop(0x04) \
 \
		label(0x06) \
		set_object_image(object, 0, TVCMDLIST_14) \
		unset_object_flag2(object, OBJFLAG2_IMMUNETOANTI) \
	endloop(0x04) \
 \
	label(0x2f) \
	assign_sound(SFX_043A, CHANNEL_7) \
	set_object_sound_playing(CHANNEL_7, object, TRUE) \
	set_object_image(object, 0, TVCMDLIST_13) \
	set_object_flag2(object, OBJFLAG2_IMMUNETOANTI) \
	set_returnlist(CHR_SELF, function) \
	set_ailist(CHR_SELF, 0x041b)

u8 func1023_holo2_object1[] = {
	holo2_do_thing(0x54, 0x0431)
	endlist
};

u8 func1024_holo2_object2[] = {
	holo2_do_thing(0x55, 0x0432)
	endlist
};

u8 func1025_holo2_object3[] = {
	holo2_do_thing(0x56, 0x0433)
	endlist
};

u8 func1026_holo2_object4[] = {
	holo2_do_thing(0x57, 0x0434)
	endlist
};

u8 func041b_holo2_part1[] = {
	beginloop(0x8f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO2, TRUE, /*goto*/ 0x04)
	endloop(0x8f)

	label(0x04)
	yield
	if_object_flag2(0x54, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	if_object_flag2(0x55, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	if_object_flag2(0x56, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	if_object_flag2(0x57, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_087) // "Holoprogram 2 has been completed successfully."
	restart_timer

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	label(0x06)
	return
	endlist
};

u8 func042f_holo2_part2[] = {
	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO2, TRUE, /*goto*/ 0x04)
	endloop(0x08)

	beginloop(0x04)
		if_within_targets_fovx_by_angle(20, /*goto*/ 0x06)
		goto_next(0x2f)

		label(0x06)
	endloop(0x04)

	label(0x2f)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x09)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	set_stage_flag(STAGEFLAG_HOLO_FAILED)
	restart_timer
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_105) // "Training failed - you must face forward."
	set_ailist(CHR_SELF, GAILIST_IDLE)
	set_object_image(0x54, 0, TVCMDLIST_12)
	set_object_image(0x55, 0, TVCMDLIST_12)
	set_object_image(0x56, 0, TVCMDLIST_12)
	set_object_image(0x57, 0, TVCMDLIST_12)

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)

	beginloop(0x09)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO2, FALSE, /*goto*/ 0x2f)
	endloop(0x09)

	label(0x2f)
	goto_first(0x08)

	endlist
};

u8 func1027_holo3_main[] = {
	label(0x80)
	disable_object(0x58)
	disable_object(0x59)
	disable_object(0x5a)
	disable_object(0x5b)
	disable_object(0x5c)
	disable_object(0x5d)
	disable_object(0x5e)
	disable_object(0x5f)
	disable_object(0x60)
	disable_object(0x61)
	disable_object(0x62)
	disable_object(0x63)
	disable_object(0x64)
	disable_object(0x73)
	disable_object(0x74)
	disable_object(0x65)
	disable_object(0x66)
	disable_object(0x67)
	disable_object(0x68)
	disable_object(0x69)
	disable_object(0x6a)
	disable_object(0x6b)
	disable_object(0x6c)
	disable_object(0x6d)
	disable_object(0x6e)
	disable_object(0x6f)
	disable_object(0x70)
	disable_object(0x71)
	disable_object(0x72)

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO3, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
	restart_timer

	beginloop(0x13)
		if_timer_gt(30, /*goto*/ 0x2f)
	endloop(0x13)

	label(0x2f)
	lock_door(0x75, 0x40)
	lock_door(0x76, 0x40)
	close_door(0x75)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x2f)
	if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x2f)
	label(0x2f)
	unset_object_flag2(0x65, OBJFLAG2_IMMUNETOANTI)
	unset_object_flag2(0x66, OBJFLAG2_IMMUNETOANTI)
	set_object_image(0x65, 0, TVCMDLIST_14)
	set_object_image(0x66, 0, TVCMDLIST_14)
	unset_stage_flag(STAGEFLAG_HOLO_ABORTING)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	unset_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	disable_object(0x45)
	enable_object(0x58)
	enable_object(0x59)
	enable_object(0x5a)
	enable_object(0x5b)
	enable_object(0x5c)
	enable_object(0x5d)
	enable_object(0x5e)
	enable_object(0x5f)
	enable_object(0x60)
	enable_object(0x61)
	enable_object(0x62)
	enable_object(0x63)
	enable_object(0x64)
	enable_object(0x73)
	enable_object(0x74)
	enable_object(0x65)
	enable_object(0x66)
	enable_object(0x67)
	enable_object(0x68)
	enable_object(0x69)
	enable_object(0x6a)
	enable_object(0x6b)
	enable_object(0x6c)
	enable_object(0x6d)
	enable_object(0x6e)
	enable_object(0x6f)
	enable_object(0x70)
	enable_object(0x71)
	enable_object(0x72)
	disable_chr(0x04)
	open_door(0x67)
	open_door(0x68)
	open_door(0x69)
	open_door(0x6a)
	open_door(0x6b)
	open_door(0x6c)
	open_door(0x6d)
	open_door(0x6e)
	open_door(0x6f)
	open_door(0x70)
	open_door(0x71)
	open_door(0x72)
	yield
	close_door(0x67)
	close_door(0x68)
	close_door(0x69)
	close_door(0x6a)
	close_door(0x6b)
	close_door(0x6c)
	close_door(0x6d)
	close_door(0x6e)
	close_door(0x6f)
	close_door(0x70)
	close_door(0x71)
	close_door(0x72)
	dprint 't','r','a','i','n','i','n','g',0,
	label(0x2f)
	label(0x91)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_098) // "Activate all the switches."
	restart_timer

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x90)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_FAILURE, TRUE, /*goto*/ 0x85)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_SUCCESS, TRUE, /*goto*/ 0x83)
		if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(1200, /*goto*/ 0x2f)
	endloop(0x82)

	label(0x2f)
	goto_first(0x91)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_HOLO3_DONE)
	dprint 'd','o','n','e',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	yield
	goto_next(0x84)

	label(0x84)
	label(0x90)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	unlock_door(0x75, 0x40)
	unlock_door(0x76, 0x40)
	remove_hudmsgs
	mute_channel(CHANNEL_5)
	mute_channel(CHANNEL_6)
	mute_channel(CHANNEL_7)
	enable_chr(0x04)
	dprint 'a','b','o','r','t','e','d',0,
	disable_object(0x58)
	disable_object(0x59)
	disable_object(0x5a)
	disable_object(0x5b)
	disable_object(0x5c)
	disable_object(0x5d)
	disable_object(0x5e)
	disable_object(0x5f)
	disable_object(0x60)
	disable_object(0x61)
	disable_object(0x62)
	disable_object(0x63)
	disable_object(0x64)
	disable_object(0x73)
	disable_object(0x74)
	disable_object(0x65)
	disable_object(0x66)
	disable_object(0x67)
	disable_object(0x68)
	disable_object(0x69)
	disable_object(0x6a)
	disable_object(0x6b)
	disable_object(0x6c)
	disable_object(0x6d)
	disable_object(0x6e)
	disable_object(0x6f)
	disable_object(0x70)
	disable_object(0x71)
	disable_object(0x72)
	enable_object(0x45)
	restart_timer

	beginloop(0x09)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x09)

	label(0x06)
	remove_hudmsgs
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func102a_holo3_part1[] = {
	beginloop(0x04)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO3, TRUE, /*goto*/ 0x2f)
	reloop(0x04)

		label(0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 300, PAD_DISH_0123, /*goto*/ 0x09)
	endloop(0x04)

	label(0x09)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x06)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_095) // "DUCK - Hold R Button, then press Down C Button to duck."
	restart_timer

	beginloop(0x0a)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x0a)

	label(0x06)
	goto_first(0x04)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func102b_holo3_part2[] = {
	beginloop(0x04)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO3, TRUE, /*goto*/ 0x2f)
		reloop(0x04)

		label(0x2f)
		if_chr_distance_to_pad_lt(CHR_BOND, 300, PAD_DISH_0124, /*goto*/ 0x09)
	endloop(0x04)

	label(0x09)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x06)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_096) // "CROUCH - When ducking, hold R Button, then press Down C Button to duck."
	restart_timer

	beginloop(0x0a)
		if_timer_gt(1200, /*goto*/ 0x06)
	endloop(0x0a)

	label(0x06)
	goto_first(0x04)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func102c_holo3_object1[] = {
	beginloop(0x04)
		if_chr_activated_object(CHR_ANY, 0x65, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	assign_sound(SFX_043A, CHANNEL_7)
	set_object_sound_playing(CHANNEL_7, 0x65, TRUE)
	set_object_image(0x65, 0, TVCMDLIST_13)
	set_object_flag2(0x65, OBJFLAG2_IMMUNETOANTI)
	set_returnlist(CHR_SELF, AILIST_HOLO3_OBJECT1)
	set_ailist(CHR_SELF, AILIST_HOLO3_CHECK_DONE)
	endlist
};

u8 func102d_holo3_object2[] = {
	beginloop(0x04)
		if_chr_activated_object(CHR_ANY, 0x66, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	assign_sound(SFX_043A, CHANNEL_7)
	set_object_sound_playing(CHANNEL_7, 0x65, TRUE)
	set_object_image(0x66, 0, TVCMDLIST_13)
	set_object_flag2(0x66, OBJFLAG2_IMMUNETOANTI)
	set_returnlist(CHR_SELF, AILIST_HOLO3_OBJECT2)
	set_ailist(CHR_SELF, AILIST_HOLO3_CHECK_DONE)
	endlist
};

u8 func041c_holo3_check_done[] = {
	label(0x04)
	yield
	if_object_flag2(0x65, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	if_object_flag2(0x66, OBJFLAG2_IMMUNETOANTI, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x06)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_097) // "Holoprogram 3 has been completed successfully."
	restart_timer

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	label(0x06)
	return
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1028_holo4_main[] = {
	label(0x80)

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO4, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
	lock_door(0x75, 0x40)
	lock_door(0x76, 0x40)
	close_door(0x75)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x2f)
	if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x2f)
	label(0x2f)
	unset_stage_flag(STAGEFLAG_HOLO_ABORTING)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	unset_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	disable_object(0x45)
	disable_chr(0x04)
	try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_0274, AILIST_HOLO4_GUARD1, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x08)
	label(0x08)
	dprint 't','r','a','i','n','i','n','g',0,
	label(0x91)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x2f)
	remove_hudmsgs
	if_chr_has_chrflag(0x0d, CHRCFLAG_NOFRIENDLYFIRE, /*goto*/ 0x61)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_107) // "Unarmed combat - knock out the target. - Press Z Button repeatedly to punch."
	goto_next(0x2f)

	label(0x61)
	if_chr_has_chrflag(0x0e, CHRCFLAG_NOFRIENDLYFIRE, /*goto*/ 0x62)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_108) // "Now try against a moving target..."
	goto_next(0x2f)

	label(0x62)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_109) // "And finally against a target that fights back."
	goto_next(0x2f)

	label(0x2f)
	restart_timer

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x90)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_FAILURE, TRUE, /*goto*/ 0x85)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_SUCCESS, TRUE, /*goto*/ 0x83)
		if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x57)
		goto_next(0x59)
		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(1200, /*goto*/ 0x2f)
	endloop(0x82)

	label(0x2f)
	goto_first(0x91)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_HOLO4_DONE)
	dprint 'd','o','n','e',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	yield
	goto_next(0x84)
	label(0x84)
	label(0x90)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	unlock_door(0x75, 0x40)
	unlock_door(0x76, 0x40)
	remove_hudmsgs
	mute_channel(CHANNEL_5)
	mute_channel(CHANNEL_6)
	mute_channel(CHANNEL_7)
	enable_chr(0x04)
	remove_chr(0x0d)
	remove_chr(0x0e)
	remove_chr(0x0f)
	dprint 'a','b','o','r','t','e','d',0,
	enable_object(0x45)
	label(0x06)
	remove_hudmsgs

	beginloop(0x6d)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO4, FALSE, /*goto*/ 0x2f)
	endloop(0x6d)

	label(0x2f)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func0403_holo4_guard1[] = {
	set_chr_id(0x0d)
	set_shotlist(AILIST_HOLO4_GUARD1)

	beginloop(0x04)
		if_chr_death_animation_finished(CHR_SELF, /*goto*/ 0x2f)
		if_chr_dead(CHR_SELF, /*goto*/ 0x2f)
		if_chr_knockedout(CHR_SELF, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	set_self_chrflag(CHRCFLAG_NOFRIENDLYFIRE)
	try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_0277, AILIST_HOLO4_GUARD2, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x08)
	label(0x08)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_108) // "Now try against a moving target..."
	set_shotlist(GAILIST_IDLE)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func0404_holo4_guard2[] = {
	set_chr_id(0x0e)
	set_shotlist(AILIST_HOLO4_GUARD2)
	label(0x04)
	yield
	if_chr_death_animation_finished(CHR_SELF, /*goto*/ 0x2f)
	if_chr_dead(CHR_SELF, /*goto*/ 0x2f)
	if_chr_knockedout(CHR_SELF, /*goto*/ 0x2f)
	goto_next(0x06)

	label(0x2f)
	set_self_chrflag(CHRCFLAG_NOFRIENDLYFIRE)
	try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_027A, AILIST_HOLO4_GUARD3, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x0a)
	label(0x0a)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_109) // "And finally against a target that fights back."
	set_shotlist(GAILIST_IDLE)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	label(0x06)
	if_distance_to_target_lt(500, /*goto*/ 0x2f)
	try_face_entity(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x08)

	beginloop(0x08)
		if_distance_to_target_lt(500, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	restart_timer
	retreat(GOPOSFLAG_RUN, 1)

	beginloop(0x09)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x09)

	label(0x06)
	goto_first(0x04)

	endlist
};

u8 func0405_holo4_guard3[] = {
	set_chr_id(0x0f)
	set_shotlist(AILIST_HOLO4_GUARD3)
	restart_timer

	beginloop(0x04)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x04)

	label(0x06)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_UNALERT)
	endlist
};

u8 func1033_holo4_part1[] = {
	beginloop(0x8f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO4, TRUE, /*goto*/ 0x04)
	endloop(0x8f)

	beginloop(0x04)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x57)
		if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x57)
		if_chr_death_animation_finished(0x0d, /*goto*/ 0x2f)
		if_chr_dead(0x0d, /*goto*/ 0x2f)
		if_chr_knockedout(0x0d, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	yield
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x57)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x57)
	if_chr_death_animation_finished(0x0e, /*goto*/ 0x2f)
	if_chr_dead(0x0e, /*goto*/ 0x2f)
	if_chr_knockedout(0x0e, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	yield
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x57)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x57)
	if_chr_death_animation_finished(0x0f, /*goto*/ 0x2f)
	if_chr_dead(0x0f, /*goto*/ 0x2f)
	if_chr_knockedout(0x0f, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	restart_timer
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_088) // "Holoprogram 4 has been completed successfully."

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x57)
		if_timer_gt(120, /*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)

	beginloop(0x57)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO4, FALSE, /*goto*/ 0x2f)
	endloop(0x57)

	label(0x2f)
	goto_first(0x8f)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1029_holo5_main[] = {
	label(0x80)

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO5, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
	lock_door(0x75, 0x40)
	lock_door(0x76, 0x40)
	close_door(0x75)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x2f)
	if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x2f)
	label(0x2f)
	unset_stage_flag(STAGEFLAG_HOLO_ABORTING)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	unset_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	disable_object(0x45)
	disable_chr(0x04)
	try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_0126, AILIST_HOLO5_INIT_GUARD1, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x06)
	label(0x06)
	yield
	dprint 't','r','a','i','n','i','n','g',0,
	label(0x91)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x2f)
	remove_hudmsgs
	if_chr_has_chrflag(0x10, CHRCFLAG_NOFRIENDLYFIRE, /*goto*/ 0x61)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_092) // "Disarm this live target if you can."
	goto_next(0x2f)

	label(0x61)
	if_chr_has_chrflag(0x11, CHRCFLAG_NOFRIENDLYFIRE, /*goto*/ 0x62)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_093) // "Knock out this target - stealth is the key."
	goto_next(0x2f)

	label(0x62)
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_094) // "And the final guard..."
	goto_next(0x2f)

	label(0x2f)
	restart_timer

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x90)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_FAILURE, TRUE, /*goto*/ 0x85)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_SUCCESS, TRUE, /*goto*/ 0x83)
		if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x57)
		goto_next(0x59)
		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(1200, /*goto*/ 0x2f)
	endloop(0x82)

	label(0x2f)
	goto_first(0x91)

	label(0x2f)
	goto_first(0x82)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_HOLO5_DONE)
	dprint 'd','o','n','e',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	yield
	goto_next(0x84)

	label(0x84)
	label(0x90)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	unlock_door(0x75, 0x40)
	unlock_door(0x76, 0x40)
	remove_hudmsgs
	mute_channel(CHANNEL_5)
	mute_channel(CHANNEL_6)
	mute_channel(CHANNEL_7)
	enable_chr(0x04)
	remove_chr(0x10)
	remove_chr(0x11)
	remove_chr(0x12)
	dprint 'a','b','o','r','t','e','d',0,
	enable_object(0x45)
	remove_hudmsgs

	beginloop(0x6d)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO5, FALSE, /*goto*/ 0x2f)
	endloop(0x6d)

	label(0x2f)
	goto_first(0x08)

	endlist
};

u8 func0406_holo5_init_guard1[] = {
#if VERSION >= VERSION_NTSC_1_0
	set_alertness(100)
#endif
	set_chr_id(0x10)
	try_equip_weapon(MODEL_CHRFALCON2, WEAPON_FALCON2, 0x40000000, /*goto*/ 0x06)
	label(0x06)
	set_ailist(CHR_SELF, AILIST_HOLO5_GUARD1)
	endlist
};

u8 func0407_holo5_guard1[] = {
	set_self_flag_bankx(CHRFLAG0_CANLOSEGUN, BANK_0)
	dprint 'C','R','E','A','T','E','D',' ','4',0,
	set_shotlist(AILIST_HOLO5_GUARD1)
	set_chr_maxdamage(CHR_SELF, 300)
	add_health_or_armor(300)
	label(0x04)
	yield
	label(0x2f)
	if_chr_death_animation_finished(CHR_SELF, /*goto*/ 0x30)
	if_chr_dead(CHR_SELF, /*goto*/ 0x30)
	if_chr_knockedout(CHR_SELF, /*goto*/ 0x30)
	if_has_gun(CHR_SELF, /*goto*/ 0x06)
	label(0x2f)
#if VERSION >= VERSION_NTSC_1_0
	set_self_flag_bankx(CHRFLAG0_00008000, BANK_0)
#else
	set_alertness(100)
#endif
	set_self_chrflag(CHRCFLAG_NOFRIENDLYFIRE)
	set_shotlist(GAILIST_IDLE)
	goto_next(0x0a)
	label(0x30)
	restart_timer
	set_self_chrflag(CHRCFLAG_INVINCIBLE)

	beginloop(0x62)
		if_timer_gt(60, /*goto*/ 0x63)
	endloop(0x62)

	label(0x63)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	set_shotlist(GAILIST_IDLE)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	label(0x0a)
	set_self_chrflag(CHRCFLAG_NOFRIENDLYFIRE)
#if VERSION >= VERSION_NTSC_1_0
	set_self_flag_bankx(CHRFLAG0_00008000, BANK_0)
#else
	set_alertness(100)
#endif
	surrender
	show_hudmsg(CHR_BOND, L_DISH_090) // "Guard has been successfully disarmed."

	beginloop(0x59)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_0272, AILIST_HOLO5_INIT_GUARD2, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x2f)
	endloop(0x59)

	label(0x2f)
	set_shotlist(GAILIST_IDLE)

	beginloop(0x0b)
	endloop(0x0b)

	label(0x06)
	if_distance_to_target_lt(300, /*goto*/ 0x2f)
	try_face_entity(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x08)

	beginloop(0x08)
		if_distance_to_target_lt(300, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	restart_timer
	retreat(GOPOSFLAG_RUN, 1)

	beginloop(0x09)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x09)

	label(0x06)
	goto_first(0x04)

	endlist
};

u8 func0408_holo5_init_guard2[] = {
	set_chr_maxdamage(CHR_SELF, 200)
	set_alertness(100)
	set_chr_id(0x11)
	try_equip_weapon(MODEL_CHRFALCON2, WEAPON_FALCON2, 0x40000000, /*goto*/ 0x06)
	label(0x06)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_093) // "Knock out this target - stealth is the key."
	set_ailist(CHR_SELF, AILIST_HOLO5_GUARD2)
	endlist
};

u8 func0409_holo5_guard2[] = {
	dprint 'C','R','E','A','T','E','D',' ','5',0,
	set_shotlist(AILIST_HOLO5_GUARD2)
	label(0x04)
	yield
	if_chr_death_animation_finished(CHR_SELF, /*goto*/ 0x2f)
	if_chr_dead(CHR_SELF, /*goto*/ 0x2f)
	if_chr_knockedout(CHR_SELF, /*goto*/ 0x2f)
	restart_timer
	assign_path(0)
	start_patrol
	label(0x08)
	yield
	dprint 'O','n',' ','P','a','t','r','o','l',0,
	if_chr_death_animation_finished(CHR_SELF, /*goto*/ 0x2f)
	if_chr_dead(CHR_SELF, /*goto*/ 0x2f)
	if_chr_knockedout(CHR_SELF, /*goto*/ 0x2f)
	if_can_see_target(/*goto*/ 0x09)
	unset_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_alertness(0)
	goto_first(0x08)

	label(0x06)
	label(0x09)
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	try_face_entity(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x0a)

	beginloop(0x0a)
		if_los_to_target(/*goto*/ 0x06)
		goto_first(0x04)

		label(0x06)
	endloop(0x0a)

	label(0x2f)
	set_self_chrflag(CHRCFLAG_INVINCIBLE)
	set_self_chrflag(CHRCFLAG_NOFRIENDLYFIRE)

	beginloop(0x57)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_0125, AILIST_HOLO5_INIT_GUARD3, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x06)
	endloop(0x57)

	label(0x06)
	set_shotlist(GAILIST_IDLE)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func040a_holo5_init_guard3[] = {
	set_reaction_speed(100)
	set_chr_id(0x12)
	try_equip_weapon(MODEL_CHRFALCON2, WEAPON_FALCON2, 0x40000000, /*goto*/ 0x06)
	label(0x06)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_094) // "And the final guard..."
	set_alertness(100)
	set_ailist(CHR_SELF, AILIST_HOLO5_GUARD3)
	endlist
};

u8 func040b_holo5_guard3[] = {
	dprint 'C','R','E','A','T','E','D',' ','6',0,
	set_shotlist(AILIST_HOLO_GUARD_ARMED_UNALERT)
	restart_timer

	beginloop(0x08)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_ARMED_UNALERT)

	beginloop(0x04)
		if_chr_death_animation_finished(CHR_SELF, /*goto*/ 0x2f)
		if_chr_dead(CHR_SELF, /*goto*/ 0x2f)
		if_chr_knockedout(CHR_SELF, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	restart_timer
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_089) // "Holoprogram 5 has been completed successfully."

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1034_holo5_part1[] = {
	beginloop(0x8f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO5, TRUE, /*goto*/ 0x2f)
	endloop(0x8f)

	label(0x2f)
	yield
	yield
	yield
	yield

	beginloop(0x04)
		if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
#if VERSION >= VERSION_NTSC_1_0
		if_chr_has_flag_bankx(0x10, CHRFLAG0_00008000, BANK_0, /*goto*/ 0x2f)
		dprint 'C','H','R',' ','4','F','D',0,
#else
		if_chr_alertness_lt(100, 0x10, /*goto*/ 0x06)
		dprint 'C','H','R',' ','4','F','D',0,
		goto_next(0x2f)
#endif
		label(0x06)
	endloop(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	if_chr_death_animation_finished(0x11, /*goto*/ 0x2f)
	if_chr_dead(0x11, /*goto*/ 0x2f)
	if_chr_knockedout(0x11, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	dprint 'C','H','R',' ','5','F','D',0,
	yield
	yield
	yield
	yield
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	if_chr_death_animation_finished(0x12, /*goto*/ 0x2f)
	if_chr_dead(0x12, /*goto*/ 0x2f)
	if_chr_knockedout(0x12, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	dprint 'C','H','R',' ','6','F','D',0,
	restart_timer
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_089) // "Holoprogram 5 has been completed successfully."

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
		if_timer_gt(120, /*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)

	beginloop(0x0d)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO5, FALSE, /*goto*/ 0x2f)
	endloop(0x0d)

	label(0x2f)
	goto_first(0x8f)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func102e_holo6_main[] = {
	label(0x80)

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO6, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
	lock_door(0x75, 0x40)
	lock_door(0x76, 0x40)
	close_door(0x75)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x2f)
	if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x2f)
	label(0x2f)
	unset_stage_flag(STAGEFLAG_HOLO_ABORTING)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	unset_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	disable_object(0x45)
	disable_chr(0x04)

	beginloop(0x57)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_0127, AILIST_HOLO6_INIT_GUARD1, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x59)
	endloop(0x57)

	beginloop(0x59)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_0128, AILIST_HOLO6_INIT_GUARD2, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x5b)
	endloop(0x59)

	beginloop(0x5b)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_0129, AILIST_HOLO6_INIT_GUARD3, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x5c)
	endloop(0x5b)

	beginloop(0x5c)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_012A, AILIST_HOLO6_INIT_GUARD4, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x5d)
	endloop(0x5c)

	label(0x5d)
	dprint 't','r','a','i','n','i','n','g',0,
	label(0x2f)
	label(0x91)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_110) // "Defeat all enemies without getting hit."
	label(0x2f)
	restart_timer

	beginloop(0x82)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x90)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_FAILURE, TRUE, /*goto*/ 0x85)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_SUCCESS, TRUE, /*goto*/ 0x83)
		if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x57)
		goto_next(0x59)
		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(1200, /*goto*/ 0x2f)
	endloop(0x82)

	label(0x2f)
	goto_first(0x91)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_HOLO6_DONE)
	dprint 'd','o','n','e',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	yield
	goto_next(0x84)

	label(0x84)
	label(0x90)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	unlock_door(0x75, 0x40)
	unlock_door(0x76, 0x40)
	remove_hudmsgs
	mute_channel(CHANNEL_5)
	mute_channel(CHANNEL_6)
	mute_channel(CHANNEL_7)
	enable_chr(0x04)
	remove_chr(0x13)
	remove_chr(0x14)
	remove_chr(0x15)
	remove_chr(0x16)
	dprint 'a','b','o','r','t','e','d',0,
	enable_object(0x45)
	label(0x06)
	remove_hudmsgs

	beginloop(0x6d)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO6, FALSE, /*goto*/ 0x2f)
	endloop(0x6d)

	label(0x2f)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func040c_holo6_init_guard1[] = {
	set_chr_id(0x13)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_UNALERT)
	endlist
};

u8 func040d_holo6_init_guard2[] = {
	set_chr_id(0x14)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_UNALERT)
	endlist
};

u8 func040e_holo6_init_guard3[] = {
	set_chr_id(0x15)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_UNALERT)
	endlist
};

u8 func040f_holo6_init_guard4[] = {
	set_chr_id(0x16)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_UNALERT)
	endlist
};

u8 func0415_holo_guard_unarmed_unalert[] = {
	set_alertness(100)
	set_chr_maxdamage(CHR_SELF, 100)
	yield
	yield
	yield
	rebuild_teams
	rebuild_squadrons
	yield
	yield
	yield
	yield
	set_action(MA_NORMAL, FALSE)
	set_shotlist(AILIST_HOLO_GUARD_UNARMED_ALERT)
	restart_timer

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x04)
		if_within_targets_fovx_by_angle(40, /*goto*/ 0x04)
	endloop(0x08)

	beginloop(0x04)
		if_distance_to_target_lt(500, /*goto*/ 0x06)
		call_rng
		if_rand_lt(1, /*goto*/ 0x06)
		label(0x2f)
	endloop(0x04)

	label(0x06)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_ALERT)
	endlist
};

u8 func0416_holo_guard_unarmed_alert[] = {
	set_shotlist(AILIST_HOLO_GUARD_UNARMED_ALERT)
	set_action(MA_UNARMEDATTACK, FALSE)
	if_chr_injured_target(CHR_SELF, /*goto*/ 0x09)
	label(0x8f)
	restart_timer
	try_run_to_target(/*goto*/ 0x08)

	beginloop(0x08)
		if_chr_stopped(/*goto*/ 0x06)
		if_distance_to_target_lt(300, /*goto*/ 0x2f)
		if_timer_gt(15, /*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	goto_first(0x8f)

	label(0x2f)
	set_returnlist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_ALERT)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_ALERT2)

	label(0x09)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0a)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	set_stage_flag(STAGEFLAG_HOLO_FAILED)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_111) // "Training failed - you have been hit."
	restart_timer
	set_ailist(CHR_SELF, GAILIST_IDLE)

	beginloop(0x5e)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x2f)
		if_timer_gt(180, /*goto*/ 0x2f)
	endloop(0x5e)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	label(0x0a)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func0416_holo_guard_unarmed_alert2[] = {
	set_action(MA_UNARMEDATTACK, FALSE)
	restart_timer

	beginloop(0x04)
		if_chr_dead(CHR_TARGET, /*goto*/ 0x57)
		if_chr_knockedout(CHR_TARGET, /*goto*/ 0x57)
		if_distance_to_target_gt(100, /*goto*/ 0x2f)
		if_can_see_attack_target(/*goto*/ 0x2f)
		if_timer_gt(120, /*goto*/ 0x10)
	endloop(0x04)

	label(0x2f)
	if_distance_to_target_gt(400, /*goto*/ 0x10)
	if_distance_to_target_lt(100, /*goto*/ 0x06)
	restart_timer
	try_run_to_target(/*goto*/ 0x08)

	beginloop(0x08)
		if_chr_dead(CHR_TARGET, /*goto*/ 0x57)
		if_chr_knockedout(CHR_TARGET, /*goto*/ 0x57)
		if_timer_gt(20, /*goto*/ 0x10)
		if_chr_stopped(/*goto*/ 0x10)
		if_target_is_player(/*goto*/ 0x0e)
		label(0x0e)
		if_distance_to_target_gt(400, /*goto*/ 0x10)
		if_distance_to_target_lt(100, /*goto*/ 0x06)
	endloop(0x08)

	label(0x2f)
	restart_timer
	goto_first(0x04)

	label(0x06)
	restart_timer
	if_target_in_fov_left(10, /*goto*/ 0x06)
	if_target_out_of_fov_left(246, /*goto*/ 0x06)
	stop_chr
	try_face_entity(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x09)

	beginloop(0x09)
		if_chr_dead(CHR_TARGET, /*goto*/ 0x57)
		if_chr_knockedout(CHR_TARGET, /*goto*/ 0x57)
		if_distance_to_target_gt(400, /*goto*/ 0x10)
		if_target_in_fov_left(10, /*goto*/ 0x06)
		if_target_out_of_fov_left(246, /*goto*/ 0x06)
		if_timer_gt(120, /*goto*/ 0x06)
	endloop(0x09)

	label(0x2f)
	restart_timer
	goto_first(0x04)

	label(0x06)
	try_punch_or_kick(/*goto*/ 0x2f)
	restart_timer
	goto_first(0x04)

	label(0x2f)

	beginloop(0x0a)
		if_timer_gt(180, /*goto*/ 0x06)
		if_chr_injured_target(CHR_SELF, /*goto*/ 0x2f)
		if_chr_stopped(/*goto*/ 0x06)
	endloop(0x0a)

	label(0x06)
	if_chr_injured_target(CHR_SELF, /*goto*/ 0x2f)
	say_quip(CHR_BOND, QUIP_MISSEDPLAYER1, 0x19, 0x03, 0x00, BANK_0, 0x00, 0x00)
	say_quip(CHR_BOND, QUIP_MISSEDPLAYER2, 0x19, 0x03, 0x01, BANK_0, 0x00, 0x00)
	goto_next(0x06)

	label(0x2f)
	say_quip(CHR_BOND, QUIP_HITPLAYER, 0x19, 0x02, 0x00, BANK_0, 0x00, 0x00)
	say_quip(CHR_BOND, QUIP_HITPLAYER, 0x19, 0x03, 0x01, BANK_0, 0x00, 0x00)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0f)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	set_stage_flag(STAGEFLAG_HOLO_FAILED)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_111) // "Training failed - you have been hit."
	restart_timer
	set_ailist(CHR_SELF, GAILIST_IDLE)

	beginloop(0x5e)
		if_timer_gt(180, /*goto*/ 0x2f)
	endloop(0x5e)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	label(0x0f)
	set_ailist(CHR_SELF, GAILIST_IDLE)

	label(0x06)
	label(0x57)
	label(0x10)
	return
	endlist
};

u8 func041a_handle_holo_failure[] = {
	beginloop(0x8f)
		if_stage_flag_eq(STAGEFLAG_HOLO_FAILED, TRUE, /*goto*/ 0x2f)
	endloop(0x8f)

	label(0x2f)
	restart_timer

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x2f)
		if_timer_gt(180, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	label(0x09)
	unset_stage_flag(STAGEFLAG_HOLO_FAILED)
	goto_first(0x8f)

	endlist
};

u8 func102f_holo1_part1[] = {
	beginloop(0x8f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO6, TRUE, /*goto*/ 0x04)
	endloop(0x8f)

	beginloop(0x04)
		yield
		yield
		yield
		dprint 'N','O',' ','D','E','A','D',0,
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
		if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
		if_chr_dead(0x13, /*goto*/ 0x2f)
		if_chr_death_animation_finished(0x13, /*goto*/ 0x2f)
		if_chr_knockedout(0x13, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	dprint 'C','H','R',' ','7','F','D',0,
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	if_chr_dead(0x14, /*goto*/ 0x2f)
	if_chr_death_animation_finished(0x14, /*goto*/ 0x2f)
	if_chr_knockedout(0x14, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	dprint 'C','H','R',' ','8','F','D',0,
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	if_chr_dead(0x15, /*goto*/ 0x2f)
	if_chr_death_animation_finished(0x15, /*goto*/ 0x2f)
	if_chr_knockedout(0x15, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	dprint 'C','H','R',' ','9','F','D',0,
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	if_chr_dead(0x16, /*goto*/ 0x2f)
	if_chr_death_animation_finished(0x16, /*goto*/ 0x2f)
	if_chr_knockedout(0x16, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	dprint 'C','H','R',' ','1','0','F','D',0,
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_112) // "Holoprogram 6 has been completed successfully."
	restart_timer

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)

	beginloop(0x0d)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO6, FALSE, /*goto*/ 0x2f)
	endloop(0x0d)

	label(0x2f)
	goto_first(0x8f)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1030_holo7_main[] = {
	label(0x80)

	beginloop(0x08)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO7, TRUE, /*goto*/ 0x81)
	endloop(0x08)

	label(0x81)
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
	lock_door(0x75, 0x40)
	lock_door(0x76, 0x40)
	close_door(0x75)
	unset_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
	if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x2f)
	if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x2f)
	label(0x2f)
	unset_stage_flag(STAGEFLAG_HOLO_ABORTING)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	unset_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	unset_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	disable_object(0x45)
	disable_chr(0x04)

	beginloop(0x57)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_012B, AILIST_HOLO7_INIT_GUARD1, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x59)
	endloop(0x57)

	beginloop(0x59)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_012C, AILIST_HOLO7_INIT_GUARD2, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x5b)
	endloop(0x59)

	beginloop(0x5b)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_012D, AILIST_HOLO7_INIT_GUARD3, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x5c)
	endloop(0x5b)

	beginloop(0x5c)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_012E, AILIST_HOLO7_INIT_GUARD4, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x5d)
	endloop(0x5c)

	beginloop(0x5d)
		try_spawn_chr_at_pad(BODY_DDSHOCK, HEAD_RANDOM, PAD_DISH_012F, AILIST_HOLO7_INIT_GUARD5, SPAWNFLAG_ALLOWONSCREEN | SPAWNFLAG_BASICGUARD | SPAWNFLAG_NOBLOOD, /*goto*/ 0x5e)
	endloop(0x5d)

	label(0x5e)
	dprint 't','r','a','i','n','i','n','g',0,
	label(0x2f)
	label(0x91)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x2f)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_110) // "Defeat all enemies without getting hit."
	label(0x2f)
	restart_timer

	beginloop(0x82)
		dprint 't','r','a','n',' ','l','o','o','p',0,
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x90)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_FAILURE, TRUE, /*goto*/ 0x85)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_HOLO_SUCCESS, TRUE, /*goto*/ 0x83)
		if_chr_activated_object(CHR_BOND, 0x75, /*goto*/ 0x57)
		if_chr_activated_object(CHR_BOND, 0x76, /*goto*/ 0x57)
		goto_next(0x59)

		label(0x57)
		set_stage_flag(STAGEFLAG_TRIGGER_CANNOTEXIT_MSG)
		label(0x59)
		if_timer_gt(1200, /*goto*/ 0x2f)
	endloop(0x82)

	label(0x2f)
	goto_first(0x91)

	label(0x85)
	dprint 'f','a','i','l',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	goto_next(0x84)

	label(0x83)
	set_savefile_flag(GAMEFILEFLAG_CI_HOLO7_DONE)
	dprint 'd','o','n','e',0,
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)
	yield
	goto_next(0x84)

	label(0x84)
	label(0x90)
#if VERSION >= VERSION_NTSC_1_0
	set_stage_flag(STAGEFLAG_CONSIDER_WARP)
#endif
	unlock_door(0x75, 0x40)
	unlock_door(0x76, 0x40)
	remove_hudmsgs
	mute_channel(CHANNEL_5)
	mute_channel(CHANNEL_6)
	mute_channel(CHANNEL_7)
	enable_chr(0x04)
	remove_chr(0x19)
	remove_chr(0x1a)
	remove_chr(0x1b)
	remove_chr(0x17)
	remove_chr(0x18)
	dprint 'a','b','o','r','t','e','d',0,
	enable_object(0x45)
	remove_hudmsgs

	beginloop(0x6d)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO7, FALSE, /*goto*/ 0x2f)
	endloop(0x6d)

	label(0x2f)
	goto_first(0x08)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func0412_holo7_init_guard1[] = {
	set_self_flag_bankx(CHRFLAG0_CANLOSEGUN, BANK_0)
	set_chr_id(0x19)
	try_equip_weapon(MODEL_CHRFALCON2, WEAPON_FALCON2, 0x00000000, /*goto*/ 0x06)
	label(0x06)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_ARMED_UNALERT)
	endlist
};

u8 func0413_holo7_init_guard2[] = {
	set_self_flag_bankx(CHRFLAG0_CANLOSEGUN, BANK_0)
	set_chr_id(0x1a)
	try_equip_weapon(MODEL_CHRFALCON2, WEAPON_FALCON2, 0x00000000, /*goto*/ 0x06)
	label(0x06)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_ARMED_UNALERT)
	endlist
};

u8 func0414_holo7_init_guard3[] = {
	set_self_flag_bankx(CHRFLAG0_CANLOSEGUN, BANK_0)
	set_chr_id(0x1b)
	try_equip_weapon(MODEL_CHRFALCON2, WEAPON_FALCON2, 0x00000000, /*goto*/ 0x06)
	label(0x06)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_ARMED_UNALERT)
	endlist
};

u8 func0410_holo7_init_guard4[] = {
	set_chr_id(0x17)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_UNALERT)
	endlist
};

u8 func0411_holo7_init_guard5[] = {
	set_chr_id(0x18)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_UNALERT)
	endlist
};

u8 func0418_holo_guard_armed_unalert[] = {
	set_accuracy(50)
	set_reaction_speed(20)
	set_chr_maxdamage(CHR_SELF, 40)
	yield
	yield
	yield
	rebuild_teams
	rebuild_squadrons
	set_action(MA_NORMAL, FALSE)
	set_shotlist(AILIST_HOLO_GUARD_UNARMED_ALERT)
	restart_timer

	beginloop(0x04)
		if_distance_to_target_lt(500, /*goto*/ 0x06)
		if_timer_gt(300, /*goto*/ 0x2f)
		if_alertness(99, OPERATOR_GREATER_THAN, /*goto*/ 0x06)
	endloop(0x04)

	label(0x2f)
	call_rng
	goto_next(0x06)

	label(0x2f)
	goto_first(0x04)

	label(0x06)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_ARMED_ALERT)
	endlist
};

u8 func0419_holo_guard_armed_alert[] = {
	set_shotlist(AILIST_HOLO_GUARD_ARMED_ALERT)
	if_has_gun(CHR_SELF, /*goto*/ 0x2f)
	increase_squadron_alertness(100)
	set_returnlist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_ALERT)
	set_ailist(CHR_SELF, AILIST_HOLO_GUARD_UNARMED_ALERT)
	label(0x2f)
	label(0x8f)
	try_attack_stand(ATTACKFLAG_AIMATTARGET | ATTACKFLAG_AIMONLY, 0, /*goto*/ 0x04)

	beginloop(0x04)
		if_can_see_attack_target(/*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	try_modify_attack(ATTACKFLAG_AIMATTARGET, 0, /*goto*/ 0x08)

	beginloop(0x08)
		if_chr_injured_target(CHR_SELF, /*goto*/ 0x2f)
		if_chr_stopped(/*goto*/ 0x06)
	endloop(0x08)

	label(0x06)
	goto_first(0x8f)

	say_quip(CHR_BOND, QUIP_HITPLAYER, 0x19, 0x02, 0x00, BANK_0, 0x00, 0x00)
	say_quip(CHR_BOND, QUIP_HITPLAYER, 0x19, 0x03, 0x01, BANK_0, 0x00, 0x00)
	label(0x2f)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	set_stage_flag(STAGEFLAG_HOLO_FAILED)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_111) // "Training failed - you have been hit."
	restart_timer
	set_ailist(CHR_SELF, GAILIST_IDLE)

	beginloop(0x5e)
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x2f)
		if_timer_gt(180, /*goto*/ 0x2f)
	endloop(0x5e)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
	label(0x0d)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1031_holo7_part1[] = {
	beginloop(0x8f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO7, TRUE, /*goto*/ 0x04)
	endloop(0x8f)

	beginloop(0x04)
		yield
		yield
		yield
		yield
		if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
		if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
		if_chr_dead(0x19, /*goto*/ 0x2f)
		if_chr_death_animation_finished(0x19, /*goto*/ 0x2f)
		if_chr_knockedout(0x19, /*goto*/ 0x2f)
	endloop(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	yield
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	if_chr_dead(0x1a, /*goto*/ 0x2f)
	if_chr_death_animation_finished(0x1a, /*goto*/ 0x2f)
	if_chr_knockedout(0x1a, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	yield
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	if_chr_dead(0x1b, /*goto*/ 0x2f)
	if_chr_death_animation_finished(0x1b, /*goto*/ 0x2f)
	if_chr_knockedout(0x1b, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	yield
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	if_chr_dead(0x17, /*goto*/ 0x2f)
	if_chr_death_animation_finished(0x17, /*goto*/ 0x2f)
	if_chr_knockedout(0x17, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	yield
	yield
	yield
	yield
	yield
	if_stage_flag_eq(STAGEFLAG_HOLO_ABORTING, TRUE, /*goto*/ 0x0d)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	if_chr_dead(0x18, /*goto*/ 0x2f)
	if_chr_death_animation_finished(0x18, /*goto*/ 0x2f)
	if_chr_knockedout(0x18, /*goto*/ 0x2f)
	goto_first(0x04)

	label(0x2f)
	if_stage_flag_eq(STAGEFLAG_GENERAL_PURPOSE, TRUE, /*goto*/ 0x0d)
	set_stage_flag(STAGEFLAG_GENERAL_PURPOSE)
	remove_hudmsgs
	show_hudmsg_middle(0x01, COLOR_04_ORANGE, L_DISH_113) // "Holoprogram 7 has been completed successfully."
	restart_timer

	beginloop(0x08)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x08)

	label(0x2f)
	set_stage_flag(STAGEFLAG_TRIGGER_HOLO_SUCCESS)

	beginloop(0x0d)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO7, FALSE, /*goto*/ 0x2f)
	endloop(0x0d)

	label(0x2f)
	goto_first(0x8f)

	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1035_manage_music[] = {
	beginloop(0x8f)
		if_stage_flag_eq(STAGEFLAG_IN_TRAINING, TRUE, /*goto*/ 0x2f)
		reloop(0x8f)

		label(0x2f)
		play_track_isolated(MUSIC_CI_TRAINING)

		beginloop(0x08)
			if_stage_flag_eq(STAGEFLAG_IN_TRAINING, FALSE, /*goto*/ 0x06)
		endloop(0x08)

		label(0x06)
		play_default_tracks
		stop_ambient_track
	endloop(0x8f)

	endlist
};

#define do_gun_msg(object, text) \
	beginloop(0x03) \
		if_chr_activated_object(CHR_ANY, object, /*goto*/ 0x2f) \
		reloop(0x03) \
 \
		label(0x2f) \
		show_hudmsg(CHR_BOND, text) \
		restart_timer \
 \
		beginloop(0x08) \
			if_timer_gt(120, /*goto*/ 0x06) \
		endloop(0x08) \
 \
		label(0x06) \
	endloop(0x03)

u8 func1038_msg_pp7[] = {
	do_gun_msg(0x1e, L_DISH_116) // "PP7"
	endlist
};

u8 func1039_msg_tt33[] = {
	do_gun_msg(0x1f, L_DISH_117) // "TT33"
	endlist
};

u8 func103a_msg_skorpion[] = {
	do_gun_msg(0x20, L_DISH_118) // "Skorpion"
	endlist
};

u8 func103b_msg_ak47[] = {
	do_gun_msg(0x21, L_DISH_119) // "AK47"
	endlist
};

u8 func103c_msg_uzi9mm[] = {
	do_gun_msg(0x22, L_DISH_120) // "Uzi 9mm"
	endlist
};

u8 func103d_msg_mp5k[] = {
	do_gun_msg(0x23, L_DISH_121) // "MP5K"
	endlist
};

u8 func103e_msg_m16[] = {
	do_gun_msg(0x24, L_DISH_122) // "M-16"
	endlist
};

u8 func103f_msg_fnp90[] = {
	do_gun_msg(0x25, L_DISH_123) // "FNP90"
	endlist
};

u8 func1000_jo_typing[] = {
	set_chr_chrflag(CHR_COOP, CHRCFLAG_HIDDEN)
	set_chr_chrflag(CHR_ANTI, CHRCFLAG_HIDDEN)
	camera_movement(ANIM_CUT_DISH_INTRO_CAM)
	cmd0175(60)
	if_controller_button_pressed(/*goto*/ 0x7b)
	play_cutscene_track(MUSIC_CI_INTRO)
	unset_chr_chrflag(CHR_BOND, CHRCFLAG_HIDDEN)
	set_chr_chrflag(CHR_BOND, CHRCFLAG_UNPLAYABLE)
	set_chr_hiddenflag(CHR_BOND, CHRHFLAG_00020000)
	chr_do_animation(ANIM_CUT_DISH_INTRO_JO, -1, -1, CHRANIMFLAG_MOVEWHENINVIS | CHRANIMFLAG_PAUSEATEND, 0, CHR_BOND, 4)
	restart_timer
	fade_to_color(0x000000ff, 0)
	fade_to_color(0x00000000, 110)

	beginloop(0x57)
		if_controller_button_pressed(/*goto*/ 0x7b)
		if_timer_gt(60, /*goto*/ 0x06)
	endloop(0x57)

	label(0x06)
	play_sound(SFX_8116, CHANNEL_5)

	beginloop(0x59)
		if_controller_button_pressed(/*goto*/ 0x7b)
		if_timer_gt(175, /*goto*/ 0x06)
	endloop(0x59)

	label(0x06)
	play_sound(SFX_TYPING_8118, CHANNEL_6)

	beginloop(0x08)
		if_camera_animating(/*goto*/ 0x2f)
		goto_next(0x7b)

		label(0x2f)
		if_controller_button_pressed(/*goto*/ 0x7b)
		label(0x2f)
	endloop(0x08)

	label(0x7b)
	unset_chr_chrflag(CHR_BOND, CHRCFLAG_UNPLAYABLE)
	set_chr_hiddenflag(CHR_BOND, CHRHFLAG_00020000)
	chr_do_animation(ANIM_CUT_DISH_INTRO_JO, -2, -1, CHRANIMFLAG_MOVEWHENINVIS | CHRANIMFLAG_PAUSEATEND, 0, CHR_BOND, 2)
	unset_chr_chrflag(CHR_COOP, CHRCFLAG_HIDDEN)
	unset_chr_chrflag(CHR_ANTI, CHRCFLAG_HIDDEN)
	enter_firstperson
	passive_mode(TRUE)
	fade_to_color(0x00000000, 0)
	yield
	yield
	yield
	yield
	stop_cutscene_track
	stop_ambient_track
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1040_lift_door_sounds[] = {
	// Disable autoguns
	yield
	set_autogun_target_team(0x8b, TEAM_ENEMY)
	set_autogun_target_team(0x8c, TEAM_ENEMY)
	set_autogun_target_team(0x8d, TEAM_ENEMY)
	restart_timer

	beginloop(0x57)
		if_timer_gt(120, /*goto*/ 0x2f)
	endloop(0x57)

	label(0x2f)
	set_object_flag(0x8b, OBJFLAG_DEACTIVATED)
	set_object_flag(0x8c, OBJFLAG_DEACTIVATED)
	set_object_flag(0x8d, OBJFLAG_DEACTIVATED)

	// Play sounds when lift doors activated
	beginloop(0x8f)
		chr_toggle_p1p2(CHR_SELF)
		if_chr_activated_object(CHR_P1P2, 0x80, /*goto*/ 0x2f)
		if_chr_activated_object(CHR_P1P2, 0x81, /*goto*/ 0x2f)
		if_chr_activated_object(CHR_P1P2, 0x82, /*goto*/ 0x2f)
		if_chr_activated_object(CHR_P1P2, 0x83, /*goto*/ 0x2f)
		if_chr_activated_object(CHR_P1P2, 0x84, /*goto*/ 0x2f)
		if_chr_activated_object(CHR_P1P2, 0x85, /*goto*/ 0x2f)
		if_chr_activated_object(CHR_P1P2, 0x86, /*goto*/ 0x2f)
		if_chr_activated_object(CHR_P1P2, 0x87, /*goto*/ 0x2f)
		reloop(0x8f)

		label(0x2f)
		play_sound(SFX_DOOR_81B0, -1)
		restart_timer

		beginloop(0x08)
			if_timer_gt(120, /*goto*/ 0x06)
		endloop(0x08)

		label(0x06)
	endloop(0x8f)

	endlist
};

s32 intro[] = {
	spawn(PAD_DISH_00F5)
	outfit(OUTFIT_DEFAULT)
	endintro
};

s32 path00[] = {
	PAD_DISH_002F,
	PAD_DISH_002D,
	-1,
};

u8 func1032_setup_lifts[] = {
	activate_lift(1, 0x43)
	activate_lift(2, 0x44)
	set_lights_state(0x0007, LIGHTOP_SET, 50, 0, 0)
	set_lights_state(0x0008, LIGHTOP_SET, 50, 0, 0)
	set_lights_state(0x0009, LIGHTOP_SET, 50, 0, 0)
	set_lights_state(0x000a, LIGHTOP_SET, 25, 0, 0)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1042_check_jo_in_training_room[] = {
	beginloop(0x04)
		// Wait until player in training
#if VERSION >= VERSION_NTSC_1_0
		dprint 'C','H','K','1',0,
#endif
		if_stage_flag_eq(STAGEFLAG_TRIGGER_UPLINK, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_ECMMINE, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CAMSPY, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_NIGHTVISION, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_DOORDECODER, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_RTRACKER, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_IR, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_XRAY, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_DISGUISE, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_TRIGGER_CLOAK, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO1, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO2, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO3, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO4, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO5, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO6, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO7, TRUE, /*goto*/ 0x2f)
		reloop(0x04)

		// And has exited the training rooms
		// 0x0014 = lobby outside holo room
		// 0x001d = entry to device training room
		// 0x001a = entry to information room
		// 0x000b = entry to carrington's office
		label(0x2f)
		if_chr_in_room(CHR_BOND, 0x00, 0x0014, /*goto*/ 0x30)
		if_chr_in_room(CHR_BOND, 0x00, 0x001d, /*goto*/ 0x2f)
		if_chr_in_room(CHR_BOND, 0x00, 0x001a, /*goto*/ 0x2f)
		if_chr_in_room(CHR_BOND, 0x00, 0x000b, /*goto*/ 0x2f)
		reloop(0x04)

		label(0x30)
		set_stage_flag(STAGEFLAG_TRIGGER_HOLO_FAILURE)
		label(0x2f)
		set_stage_flag(STAGEFLAG_TRIGGER_DEVICE_FAILURE)
		label(0x06)
#if VERSION >= VERSION_NTSC_1_0
		dprint 'C','H','K','2',0,
#endif
		yield
		yield
		yield
		yield

		label(0x57)
#if VERSION >= VERSION_NTSC_1_0
		dprint 'C','H','K','3',0,
#endif
		yield
		if_stage_flag_eq(STAGEFLAG_CONSIDER_WARP, TRUE, /*goto*/ 0x2f)
		goto_first(0x57)

		label(0x2f)
		label(0x59)
#if VERSION >= VERSION_NTSC_1_0
		dprint 'C','H','K','4',0,
#endif
		yield
		if_stage_flag_eq(STAGEFLAG_CONSIDER_WARP, FALSE, /*goto*/ 0x2f)
		goto_first(0x59)

		label(0x2f)
#if VERSION >= VERSION_NTSC_1_0
		dprint 'C','H','K','5',0,
#endif
		yield
		yield
		yield
		yield
		yield
		yield
		yield
		yield
		yield
		yield
	endloop(0x04)

	// Unreachable
	label(0x5b)
	restart_timer
	label(0x5c)
#if VERSION >= VERSION_NTSC_1_0
	dprint 'C','H','K','6',0,
#endif
	yield
	if_timer_gt(60, /*goto*/ 0x2f)
	goto_first(0x5c)
	label(0x2f)
	goto_first(0x04)

	endlist
};

u8 func1041_setup_environment[] = {
	yield
	configure_environment(0x0045, AIENVCMD_ROOM_SETOUTDOORS, TRUE)
	configure_environment(0x0046, AIENVCMD_ROOM_SETOUTDOORS, TRUE)
	configure_environment(0x0047, AIENVCMD_ROOM_SETOUTDOORS, TRUE)
	configure_environment(0x0048, AIENVCMD_ROOM_SETOUTDOORS, TRUE)
	configure_environment(0x0055, AIENVCMD_ROOM_SETOUTDOORS, TRUE)
	configure_environment(0x0056, AIENVCMD_ROOM_SETOUTDOORS, TRUE)
	set_ailist(CHR_SELF, GAILIST_IDLE)
	endlist
};

u8 func1043_remove_hovercrate[] = {
	yield
	beginloop(0x8f)
		if_object_in_room(OBJ_HOVERCRATE, 0x0016, /*goto*/ 0x08)
		if_object_in_room(OBJ_HOVERCRATE, 0x0017, /*goto*/ 0x08)
		if_object_in_room(OBJ_HOVERCRATE, 0x0018, /*goto*/ 0x08)
		if_object_in_room(OBJ_HOVERCRATE, 0x0019, /*goto*/ 0x08)
		goto_first(0x8f)

		label(0x08)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO1, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO2, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO3, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO4, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO5, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO6, TRUE, /*goto*/ 0x2f)
		if_stage_flag_eq(STAGEFLAG_IN_HOLO7, TRUE, /*goto*/ 0x2f)
		goto_first(0x8f)

		label(0x2f)
		move_object_to_pad(OBJ_HOVERCRATE, PAD_DISH_0141)
	endloop(0x8f)

	endlist
};

struct ailist ailists[] = {
	{ func1000_jo_typing,                      0x1000 },
	{ func1001_set_jo_team,                    0x1001 },
	{ func1002_devicetraining_camspy,          0x1002 },
	{ func1003_devicetraining_nightvision,     0x1003 },
	{ func1004_devicetraining_doordecoder,     0x1004 },
	{ func1005_devicetraining_xray,            0x1005 },
	{ func1006_devicetraining_disguise,        0x1006 },
	{ func1007_devicetrainign_ir,              0x1007 },
	{ func1008_devicetraining_rtracker,        0x1008 },
	{ func1009_devicetraining_cloak,           0x1009 },
	{ func100a_devicetraining_ecmmine,         0x100a },
	{ func100b_devicetraining_uplink,          0x100b },
	{ func100c_cloak_detection,                0x100c },
	{ func100e_training_unlockables,           0x100e },
	{ func100f_doorproxy_unused1,              0x100f },
	{ func1010_doorproxy,                      0x1010 },
	{ func1010_doorproxy_unused2,              0x1011 },
	{ func1012_cloak_doorproxy,                0x1012 },
	{ func1013_msg_hovercrate,                 0x1013 },
	{ func1014_msg_hoverbike,                  0x1014 },
	{ func1015_msg_doors,                      0x1015 },
	{ func1016_msg_elevators,                  0x1016 },
	{ func1017_msg_terminals,                  0x1017 },
	{ func1018_lightswitch,                    0x1018 },
	{ func1019_setup_carrington,               0x1019 },
	{ func101a_move_jo_to_training_room,       0x101a },
#if VERSION >= VERSION_NTSC_1_0
	{ func101b_ir_door,                        0x101b },
#endif
	{ func101c_holo1_main,                     0x101c },
	{ func101d_holo1_switch1,                  0x101d },
	{ func101e_holo1_switch2,                  0x101e },
	{ func101f_holo1_switch3,                  0x101f },
	{ func1020_holo1_monitor_switches,         0x1020 },
	{ func1021_holo1_code1,                    0x1021 },
	{ func1021_holo1_code2,                    0x1021 },
	{ func1021_holo1_code3,                    0x1021 },
	{ func1021_holo1_code4,                    0x1021 },
	{ func1022_holo2_main,                     0x1022 },
	{ func1023_holo2_object1,                  0x1023 },
	{ func1024_holo2_object2,                  0x1024 },
	{ func1025_holo2_object3,                  0x1025 },
	{ func1026_holo2_object4,                  0x1026 },
	{ func1027_holo3_main,                     0x1027 },
	{ func1028_holo4_main,                     0x1028 },
	{ func1029_holo5_main,                     0x1029 },
	{ func102a_holo3_part1,                    0x102a },
	{ func102b_holo3_part2,                    0x102b },
	{ func102c_holo3_object1,                  0x102c },
	{ func102d_holo3_object2,                  0x102d },
	{ func102e_holo6_main,                     0x102e },
	{ func102f_holo1_part1,                    0x102f },
	{ func1030_holo7_main,                     0x1030 },
	{ func1031_holo7_part1,                    0x1031 },
	{ func1032_setup_lifts,                    0x1032 },
	{ func1033_holo4_part1,                    0x1033 },
	{ func1034_holo5_part1,                    0x1034 },
	{ func1035_manage_music,                   0x1035 },
	{ func041a_handle_holo_failure,            0x1037 },
	{ func1038_msg_pp7,                        0x1038 },
	{ func1039_msg_tt33,                       0x1039 },
	{ func103a_msg_skorpion,                   0x103a },
	{ func103b_msg_ak47,                       0x103b },
	{ func103c_msg_uzi9mm,                     0x103c },
	{ func103d_msg_mp5k,                       0x103d },
	{ func103e_msg_m16,                        0x103e },
	{ func103f_msg_fnp90,                      0x103f },
	{ func1040_lift_door_sounds,               0x1040 },
	{ func1041_setup_environment,              0x1041 },
	{ func1042_check_jo_in_training_room,      0x1042 },
	{ func1043_remove_hovercrate,              0x1043 },
	{ func041b_holo2_part1,                    0x041b },
	{ func041c_holo3_check_done,               0x041c },
	{ func0430_holo1_check_done,               0x0430 },
	{ func0401_move_to_deviceroom,             0x0401 },
	{ func0402_move_to_holoroom,               0x0402 },
	{ func041e_colleague,                      0x041e },
	{ func041d_init_collegue_when_sighted,     0x041d },
	{ func041f_colleague1,                     0x041f },
	{ func0420_colleague2,                     0x0420 },
	{ func0421_colleague3,                     0x0421 },
	{ func0422_colleague4,                     0x0422 },
	{ func0423_colleague5,                     0x0423 },
	{ func0424_colleague6,                     0x0424 },
	{ func0425_colleague7,                     0x0425 },
	{ func0426_colleague8,                     0x0426 },
	{ func0427_colleague9,                     0x0427 },
	{ func0428_colleague10,                    0x0428 },
	{ func0429_grimshaw_disguise,              0x0429 },
	{ func042a_carrington_cloak,               0x042a },
	{ func042b_init_carrington,                0x042b },
	{ func042c_carrington_tour,                0x042c },
	{ func042f_holo2_part2,                    0x042f },
	{ func042d_unused,                         0x042d },
	{ func042e_devicegirl_reply_to_carrington, 0x042e },
	{ func0403_holo4_guard1,                   0x0403 },
	{ func0404_holo4_guard2,                   0x0404 },
	{ func0405_holo4_guard3,                   0x0405 },
	{ func0406_holo5_init_guard1,              0x0406 },
	{ func0407_holo5_guard1,                   0x0407 },
	{ func0408_holo5_init_guard2,              0x0408 },
	{ func0409_holo5_guard2,                   0x0409 },
	{ func040a_holo5_init_guard3,              0x040a },
	{ func040b_holo5_guard3,                   0x040b },
	{ func040c_holo6_init_guard1,              0x040c },
	{ func040d_holo6_init_guard2,              0x040d },
	{ func040e_holo6_init_guard3,              0x040e },
	{ func040f_holo6_init_guard4,              0x040f },
	{ func0410_holo7_init_guard4,              0x0410 },
	{ func0411_holo7_init_guard5,              0x0411 },
	{ func0412_holo7_init_guard1,              0x0412 },
	{ func0413_holo7_init_guard2,              0x0413 },
	{ func0414_holo7_init_guard3,              0x0414 },
	{ func0415_holo_guard_unarmed_unalert,     0x0415 },
	{ func0416_holo_guard_unarmed_alert,       0x0416 },
	{ func0416_holo_guard_unarmed_alert2,      0x0417 },
	{ func0418_holo_guard_armed_unalert,       0x0418 },
	{ func0419_holo_guard_armed_alert,         0x0419 },
	{ func041a_handle_holo_failure,            0x041a },
	{ func1023_holo2_object1,                  0x0431 },
	{ func1024_holo2_object2,                  0x0432 },
	{ func1025_holo2_object3,                  0x0433 },
	{ func1026_holo2_object4,                  0x0434 },
	{ func102c_holo3_object1,                  0x0435 },
	{ func102d_holo3_object2,                  0x0436 },
	{ func101d_holo1_switch1,                  0x0437 },
	{ func101e_holo1_switch2,                  0x0438 },
	{ func101f_holo1_switch3,                  0x0439 },
	{ func1020_holo1_monitor_switches,         0x043a },
	{ NULL, 0 },
};

struct path paths[] = {
	{ path00, 0, PATHFLAG_CIRCULAR },
	{ NULL, 0, 0 },
};
